Error in compiling in solo learn | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

Error in compiling in solo learn

I have recently wrote a small game in java. But i wrote in Eclipse at my computer and when I copy and paste it in solo learn compiler and then compile it, I get an error. What should I do? How should I overcome this problem?

27th Nov 2019, 10:58 AM
Birdy Yaylymov
Birdy Yaylymov - avatar
4 Answers
+ 5
It's happening because you are taking input in do while loop which is not fix means you can take any numbers of input. But Sololearn's input support only on fix numbers of input as I know. for example if you are taking input in for loop like this for(int i = 0; i < 5; i++) { int [i] = scanner.nextInt(); } So here numbers of input is fixed menas you can take 5 value at a time. Note :- Let's see what other people say. 😁
29th Nov 2019, 7:31 AM
A͢J
A͢J - avatar
+ 3
Where is your code?
27th Nov 2019, 11:11 AM
A͢J
A͢J - avatar
+ 1
Yeah, it makes sense. Thank you :)
29th Nov 2019, 7:33 AM
Birdy Yaylymov
Birdy Yaylymov - avatar
29th Nov 2019, 7:06 AM
Birdy Yaylymov
Birdy Yaylymov - avatar