Page 71 - Trackpad_ipro 4.1_Class8
P. 71

#Coding & Computational Thinking
                 Higher Order Thinking Skills (HOTS)
                    1.  A Java program is showing errors. Identify the errors and rewrite the corrected
                        code.

                        public class fullName{

                        public static void main(String[] args){

                        string “firstName=Sonia”
                        string “LastName=Mittal”

                        System.out.println(firstName +LastName);

                        }
                        }

                    2.  Cite the valid variable names in Java.

                        Computer$, 12Print, System, First Name, Emp@Dept





                  Crack The             Code                                      #Coding & Computational Thinking
                                                                                  #Experiential Learning


                 Guess! Who am I?
                     1.  I am an object-oriented programming language developed by Sun Microsystems. .............

                     2.  I am an operator used to check the equality between two values.                       .............

                     3.  I am a memory location used to store a value.                                         .............

                     4.  I am a reserved word that cannot be used as the name of a variable.                   .............
                     5.  I am a data type in Java, used to store character values.                             .............

                     6.  I am a text written inside a code for better understanding of the code.               .............

                     7.  I am the statement used to display the output of a program on the terminal.           .............


                           SDG Activity




                    Create a program  to track agricultural  production and consumption,
                    calculating yearly wastage by subtracting consumption from production.
                    The program will loop through annual data and display the results.










                                                                                              Program Coding     69
   66   67   68   69   70   71   72   73   74   75   76