Ask Question
2 October, 02:50

Write a statement that prints the following on a single output line. End with a newline.

3 2 1 Go!

Note: Whitespace (blank spaces / blank lines) matters; make sure your whitespace exactly matches the expected output.

public class OutputExample {

public static void main (String [] args) {

System. out. print ("3 2 1 Go!");

return;

}

Testing for correct output

Output is nearly correct; but whitespace differs. See highlights below

Your output

3 2 1 Go!

Expected output

3 2 1 Go!

}

Write code that prints the following. End each output line with a newline.

A1

B2

Note: Whitespace (blank spaces / blank lines) matters; make sure your whitespace exactly matches the expected output.

public class OutputExample {

public static void main (String [] args) {

System. out. println ("A1");

System. out. print ("B2");

return;

}

}

+3
Answers (1)
  1. 2 October, 03:27
    0
    public class OutputExample {

    public static void main (String [] args) {

    System. out. println ("A1");

    System. out. println ("B2");

    return;

    }

    }

    Explanation:

    The second print needs to print a new line too.

    So the line would be System. out. println ("B2")
Know the Answer?
Not Sure About the Answer?
Find an answer to your question ✅ “Write a statement that prints the following on a single output line. End with a newline. 3 2 1 Go! Note: Whitespace (blank spaces / blank ...” in 📘 Computers and Technology if you're in doubt about the correctness of the answers or there's no answer, then try to use the smart search and find answers to the similar questions.
Search for Other Answers