JAVA LAB FILE

Welcome To OOPs Lab

The activities have to be performed in making lab files

LAB-0
  • Write a program in JAVA to print 'Hello World!'

Solution File : Solution-0

LAB-1
  • Declare an integer variable called n.
  • Set the n to 5.
  • Declare an integer array called a.
  • Write a loop that initializes a to the squares of the first five integers.
  • Write a loop that will move the items in array a into another array called b, so that the order of b is the reverse the order of a.
  • Write a loop that will calculate the first 10 Fibonacci numbers

Solution File : Solution-1

LAB-2
  • Create default and parameterized constructor to calculate area of circle
  • Create two parameterized constructor. To assign radius of circle and to assign length and breadth of triangle. Then calculate area of triangle and circle 

Solution File : Solution-2

LAB-3

Solution File (FOR G1) : Solution-3
Solution File (FOR G2) :  Solution-3


Comments

Post a Comment