Comments

Thanks a lot! . Now I can understand the issue. I should stop the ios_base::sync and start to use scanf,printf instead of cin,cout hereafter in my codes. Thankss :)

Thanks for the suggestion! :)