Game Preview

Nested Loop(Grade 9)

  •  English    16     Public
    nested for loop
  •   Study   Slideshow
  • The loop that controls the number of rows in a pattern program is usually the __________ loop.
    Outee
  •  10
  • The loop that controls the number of columns or stars in a pattern is the __________ loop.
    inner
  •  10
  • If the outer loop runs 3 times and the inner loop runs 4 times, the inner loop will execute a total of __________ times.
    12
  •  10
  • TRUE or FALSE - After the inner loop ends, control goes back to the outer loop.
    TRUE
  •  10
  • The loop which guarantees at least one execution of the loop body is the __________ loop.
    Exit control loop
  •  10
  • The keyword used to immediately exit from a loop is __________.
    break
  •  10
  • In the code how many times * will be printed - for(int i = 1; i <= 3; i++) { for(int j = 1; j <= 2; j++) { System.out.print("*"); } }
    6
  •  10
  • If a loop runs without a terminating condition, it is called an __________ loop.
    infinite loop
  •  10
  • In pattern printing programs, System.out.println() is usually placed __________ the inner loop.
    after/outside
  •  10
  • The data type used to store true or false values is __________
    boolean
  •  10
  • The operator used to compare two values for equality is _________
    ==
  •  10
  • The conditional (ternary) operator uses __________ symbols.
    ? :
  •  10
  • The result of 7%3 is ____________
    1
  •  10
  • The result of the expression - 10 > 5 || 3 > 6
    true
  •  10
  • A class is a __________ for creating objects.
    blueprint
  •  10
  • Objects are created using the __________ keyword.
    new
  •  10