pages:
- 1
Daneshvar Amrollahi SAYS
Hi. How exactly we should read the inputs? My lang is C++. Can you write the while part for me? I don't want the algorithm. Just the line which reads the inputs.
Danial SAYS
The input should be until EOF:
Here is sample of EOFwhile(cin>>n){}
orwhile(scanf("%d",&n) != EOF){}
These two ways help you to get input until EOF
There are other way that you can put cin or scanf in while exept those are wrote above you can serach and find
Daneshvar Amrollahi SAYS
Thanks for your answer. I got accepted verdict for this problem.
Login please!
In order to post something you must login first. You can use the form in the top of this page.