Skip to main content
3 of 7
deleted 5 characters in body
Kevin Cruijssen
  • 131.5k
  • 13
  • 144
  • 384

#Java 8, 245 243 241 bytes

///
interface M{static void main(String[]a){System.out.print("Hello, World!");}} /*/
iinntteerrffaaccee  MM{{ssttaattiicc  vvooiidd  mmaaiinn((SSttrriinngg[[]]aa)){{SSyysstteemm..oouutt..pprriinntt((""HHeelllloo,,  WWoorrlldd!!""));;}}}}//*/

Try it here.

After removing every other character:

//itraeMsai odmi(tig])Sse.u.rn(Hlo ol!)} *
interface M{static void main(String[]a){System.out.print("Hello, World!");}}//

Try it here.

-2 bytes thanks to @OlivierGrégoire.

Explanation:

Utilizes //abc single-line comments and /*abc*/ multi-line comments.
See the Java-highlighting of the two programs to see how these type of comments are used.

Kevin Cruijssen
  • 131.5k
  • 13
  • 144
  • 384