Page 128 - 2617_JSSPS_C-7
P. 128

2.  Competency-based/Application-based questions:

                         a.   Dilip  wants  to create a Java program to check whether  he  can vote or not. Which  type  of Java
                           statement can help him do this?
                         b.   Priya has a class Student that has a constructor to initialize name, rollNumber and marks. If she wants
                           to create a new Student object with the same data as an already existing one, which constructor
                           would she choose and what would it do?



                       Explore in the Lab                                        21 st  Century   #Technology Literacy
                                                                                     Skills
               To
               Subject   Java Programming
                1.   Write a Java program by using the switch statement to display month name according to the number of
                    the month.
                2.    Write a program to input a number and check if the number is zero, positive or negative using the if….
                    else…if statement.



              For The Teacher

                  Talk about the various conditional statements of Java.

                  Discuss the use of looping statements of Java with the students.
                  Do a walk-through of all the topics covered in this chapter.















































                        Premium Edition-VII
                126
   123   124   125   126   127   128   129   130   131   132   133