System.out.println("This is a Windows path: \"C:\\Program Files\\Java\\jdk1.8.0_172\\bin\" ");
System.out.println("This is a Java string: \\\"C:\\\\Program Files\\\\Java\\\\jdk1.8.0._172\\\\bin\\\" " );
Help me figure out the error. The second line shows me a error
Resolved
Comments (3)
- Popular
- New
- Old
You must be signed in to leave a comment
Sonu Kumar
25 January 2020, 14:19
System.out.println("This is a Windows path: \"C:\\Program Files\\Java\\jdk1.8.0_172\\bin\" "); System.out.println("This is a Java string: \\\"C:\\\\Program Files\\\\Java\\\\jdk1.8.0_172\\\\bin\\\"");
just remove the space.
0
teja gowtham
24 November 2019, 03:44
in the last you have space between, \\\" and string end inverted comma " . so \\\"" keeping this in the last helps
0
Guadalupe Gagnon
23 November 2019, 16:12
try removing the space at the end of each line.
Also, when you ask for help make sure to always attach the solution.
0