University Of Pune Question Paper
M. C. M. (Semester - II) Examination - 2012
BASIC JAVA
(New 2008 Pattern)
Time : 3 Hours] [Max. Marks : 70
Instructions :
(1) Question Nos. 1 and 7 are compulsory.
(2) Solve any 3 from questions 2 to 6.
Q.1) Solve the following : [15]
(a) Which are the Life Cycle Methods of an Applet ?
(b) What is Inner Class ?
(c) What are Compilation Errors and Run-time Exception ?
(d) List Methods of File Class.
(e) Write Anonymous Class for Window Closing Event.
Q.2) Write a program which will read the file byte by byte and convert
into uppercase and copy it into another file. [15]
Q.3) Write a program that accepts two numbers and a operator like
(+, –, *, /) as command line arguments and perform the appropriate
operation indicated by the operator.
If user enters any other character, fire user-defined exception with
appropriate message “Invalid Character Exception”. [15]
OR
Q.3) Write an application to define an interface ‘CalculateResult’ with
methods CalculateTotal(), CalculatePercentage() and CalculateGrade().
Write student class with implementation of ‘CalculateResult’. Create
student object and display total marks, percentage and grade of student. [15]
Q.4) Write an application that will create the following threads : [15]
(a) To display the following sequense :
(1, 4, 9, 16, 25)
(b) The series a, c, e, g. .... z
Q.5) Write an AWT Application to draw a circle. Accept the necessary
parameters for drawing a circle and a colour to fill the circle. [15]
Q.6) Define Class Employee. Define another two subclasses :
(a) Temporary Employee Class
(b) Permanent Employee Class
(i) Calculate salary for temporary employee depending upon no. of
hours per month and overtime hours.
(ii) Calculate salary for permanent employee depending upon no. of
days per month.
(iii) Override calcsal() method
(iv) Write appropriate constructors. [15]
Q.7) Write short notes : (Any Two) [10]
(a) Abstract Class
(b) String Buffer Class
(c) Thread Class
[
M. C. M. (Semester - II) Examination - 2012
BASIC JAVA
(New 2008 Pattern)
Time : 3 Hours] [Max. Marks : 70
Instructions :
(1) Question Nos. 1 and 7 are compulsory.
(2) Solve any 3 from questions 2 to 6.
Q.1) Solve the following : [15]
(a) Which are the Life Cycle Methods of an Applet ?
(b) What is Inner Class ?
(c) What are Compilation Errors and Run-time Exception ?
(d) List Methods of File Class.
(e) Write Anonymous Class for Window Closing Event.
Q.2) Write a program which will read the file byte by byte and convert
into uppercase and copy it into another file. [15]
Q.3) Write a program that accepts two numbers and a operator like
(+, –, *, /) as command line arguments and perform the appropriate
operation indicated by the operator.
If user enters any other character, fire user-defined exception with
appropriate message “Invalid Character Exception”. [15]
OR
Q.3) Write an application to define an interface ‘CalculateResult’ with
methods CalculateTotal(), CalculatePercentage() and CalculateGrade().
Write student class with implementation of ‘CalculateResult’. Create
student object and display total marks, percentage and grade of student. [15]
Q.4) Write an application that will create the following threads : [15]
(a) To display the following sequense :
(1, 4, 9, 16, 25)
(b) The series a, c, e, g. .... z
Q.5) Write an AWT Application to draw a circle. Accept the necessary
parameters for drawing a circle and a colour to fill the circle. [15]
Q.6) Define Class Employee. Define another two subclasses :
(a) Temporary Employee Class
(b) Permanent Employee Class
(i) Calculate salary for temporary employee depending upon no. of
hours per month and overtime hours.
(ii) Calculate salary for permanent employee depending upon no. of
days per month.
(iii) Override calcsal() method
(iv) Write appropriate constructors. [15]
Q.7) Write short notes : (Any Two) [10]
(a) Abstract Class
(b) String Buffer Class
(c) Thread Class
[
0 comments:
Pen down your valuable important comments below