Professional Documents
Culture Documents
L - SCHEME
2011 - 2012
115 | P a g e
TEACHING AND SCHEME OF EXAMINATION No. of weeks per semester: 16 weeks Instructions Hours / Hours / Week Semester 6 96 Examination Internal Board Assessment Examination 25 75
Total 100
Duration
3 Hrs
OBJECTIVES: At the end of the Course, the students will be able to Analyze the given problem Think the logic to solve the given problem Compile and Interpret Java Programs Write programs using different operators and expressions. Write Java programs using sequential, conditional and Iterative statements. Handle arrays of fixed and variable size. Create vectors. Create classes and objects using Java. Implement constructors and constructor overloading. Solve problems using inheritance and Polymorphism. Create own package and interface. Create Applet programs. Handle exception arising in programs. Use GUI components in the programs. Use multithreading in programs. Work with files.
116 | P a g e
3. 4. 5.
6.
7. 8.
9. 10.
PART B
1. Write a program that accepts a shopping list of four items from the command line and stores them in a vector. Write a Menu based Program to perform the following operations using vector 1. To add an item at a specific location in the list. 2. To delete an item in the list. 3. To print the contents of the vector. 4. To delete all elements 5. To add an item at the end of the vector 2. a) Create a StringBuffer object and illustrate how to append characters. Display the capacity and length of the string buffer. b) Create a StringBuffer object and illustrate how to insert characters at the beginning. c) Create a StringBuffer object and illustrate the operations of the append() and reverse() methods.
117 | P a g e
3.
Write a program in Java with class Rectangle with the data fields width, length, area and colour. The length, width and area are of double type and colour is of string type. The methods are get_length(), get_width(), get_colour() and find_area(). Create two objects of Rectangle and compare their area and colour. If the area and colour both are the same for the objects then display Matching Rectangles, otherwise display Non-matching Rectangle.
4.
Create a class to represent complex numbers. A complex number has the form real part + i * imaginary part. Provide constructor to enable an object of this class to be initialized when it is declared. Provide a no-argument constructor with default value in case no initializes are provided. Provide public methods for the following: Addition of two complex numbers Subtraction of two complex numbers Printing complex numbers in the form (a,b) where a is the real part and b is the imaginary part. (Pass objects as arguments) i) ii) iii)
5. 6. 7.
Write a program to create a player class. Inherit the classes Cricket_player, Football_player and Hockey_player from player class. Write a program to create a package for Book details giving Book Name, Author Name, Price, Year of Publishing. A color can be created by specifying the red, green, blue values as integer parameters to the constructor of class Color. The values range from 0 to 255. Provide three horizontal scroll bars and ask the user to select the values of the colors by dragging the thumb in the scroll bar. Using the color selected, draw a rectangle. Create an applet for simple calculator to perform Addition, Subtraction, Multiplication and Division using Button, label and Text field classes. Draw a bar chart for the following details using Applets. Subject Marks Tamil 78 English 85 Maths 98 Physics 56
8. 9.
10.
Write a Java program for generating two threads, one for printing even numbers and other for printing odd numbers. SCHEME OF VALUATION Writing any one program from PART - A Writing any one program from PART - B Executing program (PART A) Executing program (PART B) Result with printout ( PART A) Result with printout ( PART B) VIVA - VOCE TOTAL 10 Marks 15 Marks 15 Marks 20 Marks 5 Marks 5 Marks 5 Marks 75 Marks
HARDWARE REQUIREMENT Desktop Computers 36 Nos Laser Printer 4 Nos SOFTWARE REQUIREMNT JDK1.3 OR JDK1.4
119 | P a g e