TK Study

Multiple choice › Python to pseudocode

Python to pseudocode

1. Python to pseudocode

Python: for index in range(n): print(index). Select the correct option to complete the equivalent pseudocode: FOR index = ______ / Display index / NEXT index

  1. 0 TO n
  2. 1 TO n
  3. 0 TO n-1
  4. 1 TO n-1
Answer

C

range(n) produces 0 to n-1. (The NESA MG answer was an image; this answer is reasoned, not copied.)