JAVA PROGRAMMING LAB
List of Experiments
- Write a Java program to create an object of type CheckingAccount with the following members.
Data members: Account number, Name of account holder, Current balanceMethods for: Constructor, Accept a deposit, Process a check, Get the current balance and Display details of an account - Create and Experiment a class for Rational Numbers in Java.
- Write a program in Java for creating and experimenting Time object.
- Write a program in Java for defining and creating a Square object.
- Write a program in Java for creating and experimenting with Bank Account object as specified in the following URL diagram:
Account String nameString accountnumberAccount(String, String)String toString()
SavingsAccount extends Account double balance SavingsAccount(String, String, double)void deposit(double)void withdraw(double)String toString()
- Write a program in Java for defining and creating an object for Circle.
- Write a program in Java for defining and implementing an Interface for Stack object.
- Write a program in Java for impelementing an Invoice object for a hardware store.
- Define an Employee object in Java for Payroll processing.
- Create and run threads in Java for displaying different Welcome messages concurrently.
- Write a java program to display the contents of a text file. (.txt file)
- Write a java program to copy one text file to another.
- Write a java program to count the number of words and lines in a text file.
- Write a program in Java for handling an exception that may occur while creating and managing a Bank Account object.
- Create and run an Applet program in Java for drawing a Circle and Rectangle as specified by the user.
FAQ on Advanced Java Programming
Q1. What is the java Bean? What are their advantages? What are various introspection Mechanism to inter information of a Bean? Explain with a suitable example.
- Dynamic BillBoard Applet
- Lavatron Applet
- JDBC
- Java Swing
- Scrabblets
Q3. What is difference between AWT and Swing?
Q4. Explain any two methods available in servlet package.
Q5. What is a java Servlet? Explain briefly the life cycle of a servlet.What are the basic steps for creating a Servlet ?
Q6. Write a java Program to create a thread that displays odd numbers starting from 1 to 100.
Q7. Write a java program to sort an array of string entered through the keyboard.
Q8. What is java Bean? What are the various steps which are needed to create a new Bean?
Q9. What do you understand by inter Thread Communication? Explain it.
Q10. Write a program to print factorial numbers.
Q11. Describe JDBC Architecture.
Q12. Discuss the various feature of the lavatron applet and srabblet.
Q13. Discuss any six methods available in Dynamic BillBoard applet.
Q14. Explain the procedure of JDBC connectivity in java with windows database. A data of 100 students having following fields in the records is to be imported in java.
Record Structure:
Record Structure:
Name : Character Array of 100
Address: Character Array of 200
Roll Number : integer
Amount Due: Float
Marks: Integer
Grade: Single character having values a, b, c, d, or e.
Write a java program to import these records from windows and send to output text file.