Page 52 - Trackpad_V2.1_class8
P. 52

21 st
                     LAB ACTIVITY                                                            Century   #Technology Literacy
                                                                                               Skills  #Critical Thinking
                      Visit your computer lab and perform the following actions:
                           Create an HTML program and use JavaScript to display your name. Use both internal JS and
                         external JS for the same program.
                           Write a program in HTML and use statements to calculate the product of two numbers and display
                         the result. Take the values as input from the user.
                           Write a JavaScript program to swap the value of two variables without using a third variable. Take
                         the values of both variables from the user.
                           Write a JavaScript program to calculate a square's area.
                           Write a JavaScript program to convert kilometres to centimetres.





                           COding Zone       COding Zone    {}      =     COding Zone                COding Zone
                                 {C ding z ne}
                                                                                               21 st
                                                                                                              []
                                                                                                  #Critical Thinking
                                                                                             Century
                                                                                              Skills
                                                                           </>
                      1.   What will be the value of x, y, and z after executing the following code in JavaScript?
                          var x = 8 + 8;
                          var y = "8" + 8;
                          var z = "Thanks" + 8;

                      2.   If a = 10, b = 2, and c = 20, then write a code in JavaScript to display the result of the following
                          expression:

                          d = a + 2 (b + c) - c/5








                         CAREER HERE
                  People who are experts in JavaScript may pursue their career as a JavaScript Developer.



                     FOR THE TEACHER

                    1.  Discuss about some more statements of JavaScript with the students.
                    2.  Explain the features of JavaScript in detail to the students.


















                   50   Trackpad (V2.1)-VIII
   47   48   49   50   51   52   53   54   55   56   57