Blue Java Chapter - 1 A. Tick The Correct Option

You might also like

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 2

Blue java chapter - 1

A. Tick the correct option.


1. Name the programming technique that implements programs as an organised collection of
interactive objects.
a. Procedure Oriented Programming b. Modular Programming
c. Object Oriented Programming d. None of these

2. Name the characteristics of Object Oriented Programming that hides the complexity and
provides a simple interface.
a. Encapsulation b. Polymorphism
c. Abstraction d. Inheritance

3. Which among the following operator is used to access individual members of an object?
a. . (dot) b. + (plus)
c. – (minus) d. / (divide)

4. Which among the following modifier is used in a ‘class’?


a. public b. default
c. Both a and b d. None of these

5. Which among the following is a valid class name?


a. Simple Interest b. SimpleInterest
c. 1SimpleInterest d. Simple@Interest

6. Which among the following is a valid object name?


a. obj1 b. 1obj
c. Obj 1 d. Obj#1

3 Revision Tour I
7. Which among the following is a valid float literal?
a. 12.36f b. 12.36F
c. 12.36 d. Both a and b

8. Which among the following is a valid octal integer literal?


a. 0178 b. 675
c. 0675 d. 0X675

9. Which among the following is a valid method of initialising?


a. boolean f=true; b. boolean f=True;
c. boolean f=’true’; d. None of these

10. Which among the following is not a punctuator?


a. ; semicolon b. , comma
c. : colon d. . dot
11. Which among the following is not a primitive data type?
a. int b. float
c. String d. char

12. What is the largest possible value that can be stored in short data type?
a. 215-1 b. 231-1
c. 27-1 d. 263-1

13. If a is of type int and b is of type float what would be the resultant data type of a+b?
a. int b. float
c. double d. short

B. State whether the following statements are True (T) or False (F).
1. Encapsulation refers to the art of hiding the complexities and giving a simple interface.
2. Procedure Oriented Language follows top down approach.
3. Java is an example of Object Oriented Language.
Computer Applications – X (ICSE Course) Answers 4
4. Hiding the complexity and giving a simple interface is called Inheritance.
5. Abstraction is same as encapsulation.
6. An object is called a class factory.
7. A class is an instance of an object.
8. A class is a mechanism to implement encapsulation.
9. Data members in a class is used to represent the characteristic of an object.
10. The new operator is used to create an object.
11. It’s a rule to have a class-name beginning in capital letter.
C. Fill in the blanks.
1. A _____________ is a template that binds together data and methods together.
2. The values in the attributes of an object is called the _________________ of an object.
3. The______________ operator is used to access the individual members of a class.
4. The keyword ___________ is used to allocate memory space for an object.
5. The default and ___________________ access modifier is used with a class.
6. An object is an identity with certain_________________ and ________________
7. The values/attributes of the characteristics of an object are called the ____________ of an
object.
8. All the complexities of a program should be _______ in such a way so that __________ is
obtained.
9. ___________ allows us to encompass the parent class’ state and behaviours into its child..
10. Poly-means ______and Morphism means ____________

You might also like