CIS121AH Powershell Chapter 9

अब Quizwiz के साथ अपने होमवर्क और परीक्षाओं को एस करें!

The step parameter must be used to increment the control variable. No other assignment is valid.

False

A for loop can be used with no parameters, with just 2 semicolons like the following: for(;;) { }

True

How many times would a loop execute with the following statement? for($x=10;$x -le 20;$x=$x+2) { }

6

The for loop will continue while the condition is false.

False

Which of the following programming errors will not cause an infinite loop?

Syntax error

A break statement terminates a loop and a continue statement moves to the next iteration of the loop.

True

A loop that does not have the ability to end is called an infinite loop.

True

The while loop continues to execute while the condition is true.

True

Which of the following is the proper syntax for a while loop?

Which of the following is the proper syntax for a while loop? while($x -lt 10) { $x++ }

Which of the following is the correct syntax of a for loop?

for ($x=0; $x -gt 10; $x++) { Write-Host $x }


संबंधित स्टडी सेट्स

Chapter 2-Psychological Research

View Set

Carman Essentials of Pediatric Nursing 3rd Ed - Ch. 4 Growth and Development of the Toddler

View Set

Dosage - Complexation and Protein Binding

View Set

Social media strategist ucertify Supercuts pt1

View Set

General Psychology: Chapters 6-11

View Set