Page 82 - Touchcode_C7_Flipbook
P. 82

Experiential Learning
                                                       Coding Task            02



                                                       To create a calculator
                   In this task, you will learn to create a calculator in MakeCode Arcade.

                   To perform the task, follow these steps:

                   Step 1:   Visit the link: https://arcade.makecode.com/, click on ‘New project’, name the
                             project as ‘calculator’ and then click on ‘Create’.

                   Step 2:  Create variables ‘a’ and ‘b’.

                   Step 3:   Drag and drop ‘set a to 0’ and ‘set b to 0’ block on
                             workspace and change the value of set a to ‘0’ to ‘10’,

                             and set ‘b’ to ‘0’ to ‘3’.

                   Step 4:  Drag and drop the ‘set a to 10’, and ‘set b to 3’ block to
                             ‘on start’ block.

                   Step 5:   From ‘Math’ select addition, subtraction, multiplication, division, remainder block.












                   Step 6:   From ‘Variables’ select variable ‘a’ and ‘b’, and drop the variable at each addition,
                             subtraction, multiplication, division, remainder block.



















                   Step 7:   Select ‘Join’ block form ‘Text’.











                   80     Touchcode-VII
   77   78   79   80   81   82   83   84   85   86   87