Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Class-5-Computing-Unit 3

Download as pdf or txt
Download as pdf or txt
You are on page 1of 3

UNIT-3

Computational thinking: A test with many questions


Fill in the blanks

1. Variables are used to store Values in a program.

2. A Conditional loop in programming repeats a block of code as long as a

specified condition is true.

3. The result of a Logical test in programming is either true or false.

4. The way that the program stops the loops is called the exit condition.

5. A Forever loop in Scratch programming repeats its code continuously.

Write the given statement true or false.

1. The "pick random" block in Scratch is used to generate random numbers within

a specified range.

Ans: True

2. The "join" block in Scratch can be used to combine not only text but also

numerical values.

Ans: True

3. The "forever" block in Scratch creates a loop that runs indefinitely without

any condition.

IPS CLASS 5/COMPUTING Page 1 of 3


Ans: True

4. The "if" block in Scratch allows you to perform logical tests and execute

specific code only if the condition is false.

Ans: False

5. In Scratch programming, variables can only store numerical values.

Ans: False

Answer the following.

1. Write two main types of loops.

Ans: Counter loop- It’s a fixed loop that repeats a set number of times.

Conditional loop- It’s a condition-controlled loop that is controlled by a logical

test.

2. What blocks in Scratch enable the creation of repetitive actions?

Ans: Blocks like "Repeat" and "Forever" in Scratch enable the creation of

repetitive actions.

3. Write the difference between repeat and repeat until loops.

Ans: Repeat: Has a predetermined, fixed number of iterations.

Repeat Until: Continues to repeat until a specified condition becomes true.

4. What are the advantages and disadvantages of using a conditional loop?

Ans: Advantages:

• The user gets lots of chances to answer.


IPS CLASS 5/COMPUTING Page 2 of 3
• The user can keep trying until they get the answer right.

Disadvantages

• If the user can’t get the right answer, they can’t stop the loop. They

can’t move on to a new question.

5. How to use random numbers in a Scratch program?

Ans: Step 1: To generate a random number within a specific range, use the "pick

random" block from the "Operators" category.

Step 2: Then drag and drop the "pick random" block into your script area.

IPS CLASS 5/COMPUTING Page 3 of 3

You might also like