Well the second question bugged me a lot i thought of dp and stuff but brute force worked wasted a lot of time there. The third question was completely implementation based but got wrecked by SIGSEV found the error in the last minute!
My rank is 580. Will my rating increase? ( Not a big deal, but still curious lol )