Uh... Happy New Year!

  • 1
  • Locked
Remove comments from part of the code so that "Happy New Year" appears on the screen.
You can't complete this task, because you're not signed in.
Comments (10)
  • Popular
  • New
  • Old
You must be signed in to leave a comment
Aarav Chourishi
Level 2 , United Kingdom, United Kingdom
5 June, 16:26
cant believe you had to uncomment " " i just put a space before year which still should be correct
The OG
Level 1 , United Kingdom
21 March, 19:36
im so confused on how to do this at all
javist Android Developer
24 February, 17:27
make all tasks like Code Entry tasks for more typing effectiveness
Anonymous #10916593
Level 3 , Borger, United States
12 January, 00:19
why does .println not put year on a separate line here? I thought it always started a new line when you use .println
Roman
Level 41
17 January, 07:42
Show me the code that you think is wrong.
Anonymous #10916593
Level 3 , Borger, United States
19 January, 01:33
System.out.print("Happy New"); System.out.print(" "); System.out.println("Year"); I just seems like it should display "Happy New Year" But actually displays "Happy New Year"
Roman
Level 41
21 January, 09:01
I just seems like it should display "Happy New Year" Why? System.out.print(" "); System.out.print does not move the cursor to a new line
Anonymous #10916593
Level 3 , Borger, United States
24 January, 23:29
I guess my reasoning is System.out.println() starts a new line right? so in the case of System.out.println("happy"); System.out.print(" new"); System.out.println("year"); you would get: Happy new year right? Does my reasoning make sense? I'm guessing this is a technicality if .print is used before any instance of .println.
John Squirrels Website Admin at CodeGym
25 January, 07:08
If you use System.out.println, then the subsequent text will appear on the next line. so in the case of System.out.println("happy"); System.out.print(" new"); System.out.println("year"); you would get: Happy new year right? Not exactly. The output would be next: happy newyear
Manuel Arenas Arce
Level 2 , United States of America, United States
28 July, 22:16
PrintIn makes it so that the next text that will be displayed would be on another line it doesn't make the code in that printIn appear in another line. when it said System.out.printIn("year"); it meant that after "year" it would make the next print or printIn be in a separate line it does not make the code be on a separate line, for that to be it would need: System.out.printIn("happy new"); System.out.print("year"); this makes the text say Happy new year. In a few words, the printIn method makes the next word appear on the next line.