The tasks for week 4 are as follows:
Week problem: IV -> 00481 What Goes Up Weekend problem: V -> 00507 Jill Rides Again Suggested bonus: CVIII -> 10819 Trouble of 13-Dots
You must submit your solutions on http://uva.onlinejudge.org/
You can browse to these problems from the online judge website by clicking on Browse Problems, Contest Volumes, and then selecting the contest volume as indicated above.
Please post below which of the questions you have been able to finish.
For each task, please let us know how much time you have spent on understanding / coding / debugging.
For each task let us know what the hardest part was. (This can be anything, ranging from not having read the problem to forgetting about a border case, to a semicolon in the wrong spot that screwed up an if-statement...)
I have a question about the first problem. How do you know when to stop reading from the input? Does the stdin has some kind of EOF?
Good question!
For IOIs you will always know when the input is finished.
Also on stdin you will have EOF.
Try it by writing your own program, and then do program < input.txt
You'll see that you can find stein for your input.txt
If you're typing things manually you can use CTRL-D to send EOF.
You can just do cin.eof() like files