Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

19TE008

ARash Mahupabna peacock


Pge
Past 2

Ans 20) # indude eiostream hz


Using nemespace std
epoia
claas Exponent
oadite. jnt value;
peullic
Exponen Link a int b:1) z
value =1,
o Cint i 1, i«sb ie+)_
Valuu- valve *a,
3
i void showl)
cou e valuu,
3
ind main)2
Exponen elC1o,2)., e2(5)>
e1.show I/Dut put : 10o
e2show D,- LOuhut S

As2 #ilude <iostkeem.hz


dass Add &
int 14, 2
palie
Ada L)
3
Add(int a, int b):z(a) ,4lb)
3
Add Ad& Teacher s Signature..
19TE0086
ARosh Mahapadsa

void Caleulars (void)


vold dipay (od )-

Add: Ad (A AA Lp)

Lout<e" Value_of x and y


or ne ojec: ez e
andceq Leendl,

vod Add:: calendahe )&_


2 Mt

id Pdd dipla,S
Loe2

vai int main) 2_


tdd ala,5.);
Add bla) /Y x adr new pbjet:5 nd
u caludare)
b. display,L 11
19JE00o8
Peaok
HRash Mahapatsa ate

Ars 29 indude closrea hz


Usirg amaspace s
clas playex z
_chax name C3d
int age
Void inputC)&
inRqL outee "Erher nwme:"
ciA77-Aam_dnzz name,
cout ee"Enkex ege:
Linz age

void display
cout ee "Name <neme zeend
(pu ee "Age: ageszeendl ,
3
int mainl)
player p(57:
fnr int i: 0 i<S,i+)
pl.input)
fr CInt i-0 i5 i )
pl.duplay)3
Tem O

Teachers Signature..
193E 0D86
ARouh Maapstaa Pssk
ate

As 24)
#indude siosteam.h
VSing nameRpate std,
cdas Nombex
i
pudic
NomeexCinta, int b):6 xla), y{b)
3
omberopexahy t(Nombex n)
t VUmbex temp(O,0);
Xt n
Temp. x
tump y4An-y-
yehm_fempj
3
lint main()&
Numbex n1(5,4))
Numoer n2. (7, 3
Nvmbex n3 0,0)
n3 n1.opexaoy +(n2)
Coutex= "4n2:xee" n2.y<m
Couk : "«nan u"en3.y eend
etm 0,

You might also like