If k is integer, how many times will the following "while" loop be executed?k = 50 while k > 1: print(k) k = k // 2
A: 3
B: 4
C: 5
D: 6
A: 3
B: 4
C: 5
D: 6
举一反三
- If k is integer, how many times will the following "while" loop be executed?k = 50 while k >; 1: print(k) k = k // 2 A: 3 B: 4 C: 5 D: 6
- How many times will the following while loop execute? [br][/br]k = 50 [br][/br]while k > 1: [br][/br]print(k) [br][/br]k = k // 2 A: 5 B: 3 C: 4 D: 6
- How many times will the loop body be executed? int k=0; while(k=1)k++;
- How many times is the loop body " k++;"<br/>executed in the following program segment? ( )<br/>int k=0; while(k=1)<br/>k++; A: Infinite B: 1 C: 0 D: compile error
- Private Sub Form_Click() k = 0: a = 0 Do While k < 70 k = k + 2 k = k * k + k a = a + k Loop Print a,k End Sub