Link to problem: http://codeforces.me/problemset/problem/546/D My solution to this problem matches that of other folks but, for some reason I keep getting TLE on test suite 3. Can anyone shed some light on why this might be? Your help is appreciated.
Link to submission: http://codeforces.me/contest/546/submission/28127026









Try using a faster output method. Such as Java's PrintWriter