Question: What does the following line of code do? System.out.println(); A. Breaks your computer. Do not write this line of code into

What does the following line of code do?

System.out.println();
    A.     Breaks your computer. Do not write this line of code into your program!
    B.     Nothing happens because you need to write something between the parentheses, for example: System.out.println("hello!");
    C.     Causes an error because you need to write something between the parentheses, for example: System.out.println("hello!");
    D.     Prints an empty line. This is helpful for spacing things out when printing multiple things.



2. You are required to download jGrasp for this class. What is it used for?

(Check all that apply, or none if applicable.)
    A.     Asking the instructor for help with my program
    B.     Compiling my Java program
    C.     Debugging my Java program
    D.     Submitting my program to the instructor for grading
    E.     Editing my Java program



3. Match the escape sequence to what it does.
    Choices - use a choice only once      
A.     t
B.    
C.     q
D.     "
E.    
    Match each of the following to a choice    
1.     Lets you print a quotation mark    
2.     Lets you print a backslash    
3.     This isn't an escape sequence!    
4.     Moves to the next line    
5.     Equivalent to pressing the tab key    



4. Are there any mistakes in the following Java code?

public class PrintMyName {
   public static void main(String() args) {
      // Prints name
      System.out.println("My name is Elmo.";
   }
}
    A.     Yes, there is one mistake.
    B.     Yes, there are two mistakes.
    C.     Yes, there are three mistakes.
    D.     No, there are no mistakes in this code.

Step by Step Solution

3.52 Rating (165 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

The detailed answer for the above question is provided below In Java to print something on the ... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!