I would like to know which case this code in Java does not work. I have tried several cases and no meeting which is failing. Can you help me telling which case fails?
The code Java is:
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.ArrayList;
// uva code 10020 ...
Search found 4 matches
- Thu Dec 13, 2012 1:16 am
- Forum: Volume 100 (10000-10099)
- Topic: 10020 - Minimal coverage
- Replies: 57
- Views: 27298
- Tue Dec 04, 2012 4:29 am
- Forum: Java
- Topic: Problems input
- Replies: 6
- Views: 5583
Re: Problems input
Thanks, I was able to fix the problem, but now I have a new problem with the entry:
if not tell me which is the termination condition, as I know I'll finish the entry?
if not tell me which is the termination condition, as I know I'll finish the entry?
- Sun Nov 18, 2012 4:40 pm
- Forum: Java
- Topic: Problems input
- Replies: 6
- Views: 5583
Re: Problems input
I read only one line?
2 \ n \ n1 \ n-1 0 \ n-5 -3 \ n2 5 \ n0 0 \ n \ n1 \ n-1 0 \ n0 1 \ n0 0
or should I read several lines?
2
1
-1 0
-5 -3
2 5
0 0
1
-1 0
0 1
0 0
2 \ n \ n1 \ n-1 0 \ n-5 -3 \ n2 5 \ n0 0 \ n \ n1 \ n-1 0 \ n0 1 \ n0 0
or should I read several lines?
2
1
-1 0
-5 -3
2 5
0 0
1
-1 0
0 1
0 0
- Wed Nov 14, 2012 7:37 pm
- Forum: Java
- Topic: Problems input
- Replies: 6
- Views: 5583
Problems input
If I have the following entry:
2
1
-1 0
-5 -3
2 5
0 0
1
-1 0
0 1
0 0
should read as java?? with a variable BufferedReader and readLine () method and read line by line? or just read a single line in the following format:
2 \ n \ n1 \ n-1 0 \ n-5 -3 \ n2 5 \ n0 0 \ n \ n1 \ n-1 0 \ n0 1 \ n0 0
2
1
-1 0
-5 -3
2 5
0 0
1
-1 0
0 1
0 0
should read as java?? with a variable BufferedReader and readLine () method and read line by line? or just read a single line in the following format:
2 \ n \ n1 \ n-1 0 \ n-5 -3 \ n2 5 \ n0 0 \ n \ n1 \ n-1 0 \ n0 1 \ n0 0