99 Write a Java program to illustrate multilevel inheritance such that country is inherited from continent. State is inherited from country. Display the place, state, country and continent.

Code: import java.io.InputStreamReader; import java.io.BufferedReader; import java.io.IOException; class Continent {   String con...
Read More

98 Create class student having method getdata() which should accept details of student such as rollno, name and marks of 3 subject. Extend class result from student. Define a method cal() in result to calculate the total and average of marks and display it.

Code: import java.util.Scanner; class Student { // Instance Variable int rollno,m1,m2,m3; String name;    void getdata() { ...
Read More