Questions :
-
Create a Employee class with ename,designation,salary,email as instance variables. Create all getter/setter Now Create an Employee and print like: Ankan works as Developer with emailid [email protected] and earns 5k per annum.
-
Create Teacher class with tname,subject and yrsOfExp with getter/setter Create Student class with sname,degree and college with getter/setter Now create another class having 2 static methods to create relationship b/w both The O/P should look like following: Ankan takes java class under Amitava Sir , Amitava teaches OOPS design to Madhu who reads as Btech Student in UEM college
-
Write a Java program to create a class called "Book" with attributes for title, author, and ISBN, and methods to add and remove books given from command prompt also using JOptionPane.
-
Create a java class LED having id brand and price. Now create 2 OLED as Sony and Samsung now compare their price and the higher priced tv name should be changed to Premium Model then print all to console.
-
Create a Java class Laptop with brand , price and processor type. Now Create HP LENOVO and DELL -3 laptops. Now Create an User class with username and address and the user should compare all processors and will puchase only Intel Core Ultra based laptop.
-
Apply Has-A relationship to create the following A person HAS AN address.(USE LOMBOK)
-
Create a Shop which sells only Mobiles. Now create a customer and visit the shop and purchase a VIVO mobile if it has Android 15 only.
-
Create a class to check where a student is eligible 2 vote in an election by checking age.
-
Create a java class that will check whether a person's name is palindrome or not.
-
Create a class that will apply a tax of 10% to the basic salary and give a bonus of 2% of basic salary and add a travelling allowance of 1.5% of basic salary. Now find the annual salary of the employee.