Professional Documents
Culture Documents
Lab-7 Harsh Singh
Lab-7 Harsh Singh
A lab Submitted
in Partial Fulfilment of the Requirements
for the Degree of
Bachelor of Technology/BTech (CSE)
import java.util.*;
class Animal{
void sleep(){
System.out.println("Zzzzzz");
void Noise(){
System.out.println("Grrrr");
void roam(){
System.out.println("Howling:Ouooooo!");
void Noise(){
System.out.println("Roar:Rrrrrr");
void Noise(){
System.out.println("Meow Meow");
int a=sc.nextInt();
switch(a){
case 1: {
s3.Noise();
s3.sleep();
s3.roam();
break;
}
case 2: {
s1.Noise();
s1.sleep();
s1.roam();
break;
case 3: {
s2.Noise();
s2.sleep();
s2.roam();
break;
default:
#OUTPUT
#CODE
import java.util.Scanner;
class Shape{
System.out.println(a*a);
System.out.println(a*b);
System.out.println((3.14)*a*a);
}
class Main
int a = sc.nextInt();
int b = sc.nextInt();
x.area(a);
x.area(a,b);
y.area(a);
#OUTPUT