You are on page 1of 7

CPP OUTOUTS

1A……………………….
Enter a number: 85
Sum is= 13

1B………………………….
Enter the Number= 789
Not Armstrong Number.

Enter the Number= 371


Armstrong Number.

1C………………………………..
Enter the value of N
50

2 3 5 7 11 13 17 19 23 29 31 37 41 43 47

2……………………………….
Enter the size of the array : 5
Enter the elements of the array : 24
32
17
52
31
Largest element : 52
Smallest element : 17
3………………………………………
Enter total number of students: 3
Enter details of student 1:
Enter name: JAY
Enter roll number: 001
Enter total marks outof 500: 450
Enter details of student 2:
Enter name: JAY2
Enter roll number: 002
Enter total marks outof 500: 470
Enter details of student 3:
Enter name: JAY3
Enter roll number: 003
Enter total marks outof 500: 480

Details of student 1:
Student details:
Name:JAY,Roll Number:1,Total:450,Percentage:90
Details of student 2:
Student details:
Name:JAY2,Roll Number:2,Total:470,Percentage:94
Details of student 3:
Student details:
Name:JAY3,Roll Number:3,Total:480,Percentage:96

4………………………………………..
45
45.45
5……………………………………
Area of the rectangle =30
Area of the circle 78.5
Area of the square = 25

6……………………………………
p1.x = 10, p1.y = 15
p2.x = 10, p2.y = 15

7A………………………………………
Length of box: 10

7B……………………………………
value of x is : 5

8A…………………………………….
DEFAULT CONSTRUCTOR
Default Constructor Invoked
Default Constructor Invoked

PARAMETERIZED CONSTRUCTOR
101 Sonoo 890000
102 Nakul 59000

COPY CONSTRUCTOR
20
8B……………………………….
INSIDE OF A CLASS
Default Constructor Invoked
Default Constructor Invoked

OUTSIDE OF A CLASS
I’m Constructor: Outside Class
Values :10 20

8C…………………………………….
INSIDE OF A ONE CLASS
default constructor is called
Parameterized constructor
parameter values 10
Copy constructor
copied parameter value 10

IN DIFFERENT CLASSES
default constructor is called
Parameterized constructor
parameter values 10
Copy constructor
copied parameter value 10
9A………………………………………
30
55

9B………………………………………..
UNARY OPEREATOR OVERLOADING
Feet & Inches(Decrement): 7'8
BINARAY OPEREATOR OVERLODING
Enter the first number: 52
Enter the first number: 64
The sum of two numbers is: 116

10A………………………………..
Salary: 60000
Bonus: 5000

10B………………………………
Eating...
Barking...
Weeping...

10C………………………………
The value of a is : 10
The value of b is : 20
Addition of a and b is : 30
11…………………………….
default constructor is called
Parameterized constructor
parameter values 10
Copy constructor
copied parameter value 10

12A…………………………………….
In Derived

12B………………………………….
Virtual Function in Derived class

13B……………………………………
Constructing base
Constructing derived
Destructing derived
Destructing base

14…………………………………..
30
55

15…………………………………
Derived Function
Base Function
16A……………………………………
square of a 4
square of I 6.25
square of x 0

16B……………………………………..
enter an integer vlaue
15
result=225
enter an float vlaue
12.5
result=156.25
enter an double vlaue
73.2345
result=5363.29

You might also like