Basic HTML Version

|  | Table of Contents |  | View Full Version

Page 115 - 2609_Logiccode
P. 115

    REVISIT

                       ▶  A variable is a name given to a location in the computer’s memory to store values or data.
                       ▶   Each variable in a program must have a unique name; you cannot use the same name for more than one
                         variable.
                       ▶  We can create a variable using the Variables block category.

                       ▶  The process of assigning a value to a variable is called initialisation.
                       ▶   Math blocks are used to perform various mathematical operations and computations in your games and
                         projects, like addition, subtraction, multiplication and division.

                       ▶  Logic blocks are used to handle decision-making and control flow in your projects.

                     1.  Tick ( ) the correct option.
                        a.   What are the fundamental blocks used to implement a decision-making capability in a MakeCode
                          Arcade project?
                            (i)  Math blocks                               (ii)  Logic blocks

                           (iii)  Game blocks                             (iv)  Loops blocks
                        b.  Which of the following blocks reverses the result of a condition?

                            (i)  or                                        (ii)  if-then
                           (iii)  and                                     (iv)  not
                        c.  If all the conditions used with the OR block are false, what will be the overall result?

                            (i)  True                                      (ii)  False
                           (iii)  No result will be generated             (iv)  None of these

                        d.  Which of the following TRUE about variables?
                            (i)  A variable has a name                     (ii)  A variable has a type
                           (iii)  A variable has a value                  (iv)  All of these

                     2.  Fill in the blanks using the words from the help box.

                                                   initialisation, variable, letter, Game

                        a.  A ____________ is a name given to a location in the computer’s memory to store values or data.

                        b.  Variable names must begin with a ____________ or an underscore.

                        c.  This process of assigning a value to a variable is called ____________.
                        d.  The splash block is present in the ____________ blocks category.

                                                                                             More on MakeCode Arcade  113

| 110 111 112 113 114 115 116 117 118 119 120 |