+ 1
What if I want to print out on the screen a text with quotes "inverted commas" in java.
want to see "Hello World!" not Hello World
6 odpowiedzi
+ 2
Use \" for double inverted commas and \' for single
hope it helps you
+ 1
how you implement it, it should be like this
System.out.print("\"Hello\"");
+ 1
does this work?
+ 1
public class Program
{
public static void main(String[] args) {
System.out.print("\"Google\" is a search engine and I \"love\" to use it.");
}
}
0
nope... doesn't work 😣😓
0
yes worked! you are great!! thanks a lot!!