Computer Applications
How are following two scripts different from one another ?
![How are following two scripts different from one another? Scratch Programming I, Computer Applications Code 165 Sumita Arora Solutions CBSE Class 9.](https://cdn1.knowledgeboat.com/img/drc9/q2-1-aq-scratch-computer-code-165-sumita-solutions-449x490.png)
![How are following two scripts different from one another? Scratch Programming I, Computer Applications Code 165 Sumita Arora Solutions CBSE Class 9.](https://cdn1.knowledgeboat.com/img/drc9/q2-2-aq-scratch-computer-code-165-sumita-solutions-432x540.png)
Scratch
1 Like
Answer
The key distinction between the given scripts is that in the first script, the "Woof!" message will be displayed once when the sprite is touching "Sprite1". In the second script, because of the forever loop, the "Woof!" message will be repeatedly displayed every time the sprite is touching "Sprite1", as long as the program is running.
Answered By
1 Like
Related Questions
What is an if-statement ? Give two examples.
Carefully go through some sample scripts given below. What is happening in each of these scripts ?
Create a fun game in scratch where there are two sprites on the stage cat sprite and a ball sprite. Ball is forever moving on stage. The cat sprite's movement is controlled by pressing all arrow keys : up/down/left/right. If the cat sprite touched the ball sprite, it exclaims "Hurray!!".
Write a script/program to draw a heptagon on the stage.