+ 3
What’s wrong with my code?
I didn’t even start coding. Getting this problem :/ https://code.sololearn.com/c78nyhPD80Lu/?ref=app
6 Respuestas
+ 4
Like this as others have said.
https://code.sololearn.com/cxmip9sA237R/?ref=app
+ 3
I see. that makes sense. thank you guys.
I’m just used to c++ only needing 2 statments. check my code. is there a way to do it like that?
https://code.sololearn.com/cVa04y0Xnsoe/?ref=app
+ 2
What you pass into the println function is the Scanner object, that's why the output is weird. If you want a string, write this instead after you initialize the Scanner
String s = w.nextLine();
System.out.println(s);
+ 2
got it! thanks again :)