Answers

Question and Answer:

  Home  Test Analyst

⟩ 0 program TRICKY 1 var1, var2, var3 integer 2 begin 3 read ( var2 ) 4 read ( var1 ) 5 while var2 < 10 loop 6 var3 = var2 + var1 7 var2 = 4 8 var1 = var2 + 1 9 print ( var3 ) 10 if var1 = 5 then 11 print ( var1 ) 12 else 13 print ( var1+1 ) 14 endif 15 var2 = var2 + 1 16 endloop 17 write ( "Wow - that was tricky!" ) 18 write ( "But the answer is…" ) 19 write ( var2+var1 ) 20 end program TRICKY Which of the following statements about the TRICKY program MOST correctly describes any control flow anomalies in it? A. The TRICKY program contains unreachable code and an infinite loop B. The TRICKY program contains no control flow anomalies C. The TRICKY program contains unreachable code D. The TRICKY program contains a loop with multiple entry points

A. The TRICKY program contains unreachable code and an infinite loop

 122 views

More Questions for you: