Python
Python
Daty tgpel:
Nuneoic
2) Dictioncu
oolean
Conplex Luple
LNumaser
becteqt.
2:gaz"?
1
mathng foet and eon
LooRs
(rhile,
fr
baantkiny pocqam P uGed to chenge the
23 el"e
in
Page No.
Date
eloe
bg
int("dequaldo b")
else
print Caisnt satal fo')
a Gequente
{nuits= 'pole", bcnana
printr).
the else Sletment
faulsC'agple, "banctca
painta)
else
Punt("Çinished ")
uhen eepion
Can 'oue or 'Hhaocm" the Cxcephon.
to - let you teat a oloce af
Code
pon)
excpt NemeGar:
define).
ontc tariable xi5nod
int(" Somdhing erorg")
rnt(" trtor Noung oreong")
Finally : ("he tg ExcupFis finished
)funcion' block ot
Cade that Porfom d
Pint CHelloU)
dee Enamec)4)
Lich dekut
det fnamel a=le):
print (x)
rgumtnt
def SumCtaxqp ) i
Lolud
total fum
Page NO
Dale
file managEmpAPnt
a Apoocess of intecacing couh files.
fanion lice edrg criirg scpnirg
and delitry
gthon poolde buit in funcion and
for Pile manyemn)
Models for
AopEnungl
file= openl"Exanplet
4 Recdingxecdc), rEedline),eudlineio)
Fte
Content= Pile,yecdc)ax file.eddline
pointlcoh tent)
file open("Example.tx4!,"o)
pile wme(" go mtti ng)
file.c[oSe.
CileopenCExumple td"a")
Ele.toritel"Somthirg)
leclo Se
Page No
Date
Exegt Xtbtentce
6)checidngy Ere fle
Delctinsy' -
OS.emoye.
6 Lohâitcynce
inherikence i nachaniám
Hact cttrtoce coloo. cllooclcaseto
taheto eAmctthod&tom
)dpSGe of inheitarce.
A)Gingle .
2) malipl e
Hipachical
Page No.
Data
) Gingle'
cleas Animc:
def (Gel)
Print (Animu ')
dass eylAnimel)
detait --fGelf)
deflbente CbelfJo
d= DogS.
d baytels
d. Gpele
dmultiple
dass oi
def fly Cself)e
paint Crty)
det cwalk(Belt)a
Pant ceseale)
CLcasg (3cet ("ire Arimal
pusS
d.flyc
lehilcef
pass
tahical) (a( Clago
Jgoesplf)o def
def
o cahi
cal c ctass
dhonlel)
ford d= eto
pabo ef
(Cws forsd class
hanelGealf)8 def
(uahiaul) Car Clags
(åniue'y print
(3elB daie det
apahice class
Date
No. Page
Page No
Date
cluss lahical o
det Aee Csel):
Print(tauhica
ctass (cxr Cahicl)
def carfjatneCsel):
pzint Cod
d= nlame C
ALerne.
dbicenlcmel
d o Name)
d. kypel)
Page No.
Date
Regalg funpion
prit
Þrint CGqtlG)) )2s
Qnnbdefemaion
Geprt = lambda
erintor Bant(6))23
numbe)
Page No.
Date
numbce)
(2int (euen)
oom funtobl import educe
Mum L 2 345)
humbee6)
poin Cecen
pp
m capplies untronto oll aelement
Cle PIE elemend louse bn Conditon
aeduce sedace eomtetby Cenutivcley.
$) funcHOn decortor6'
modifie that modifee the behauica
of oha8r funcHOn cr metaerds
def helioé)&
(orit Cheilo co)
FuncrBon 4h perneos
de add Cu b)
pnt Catb)
+addlte2)
Gutputl Cuellcome
+antthunlego
poc,tHonal angement
(Paga No.
|Data
angs Colleet
all poi Hionel aocpurn ont
aGs to he funcHon ioto 4uple
def fan (t,
print()
AunCl22)
fun(as b=2,l=3)
Page No.
Date
cof init--CSele)
Celfname= gae!
d= democ)
ete prin (deName)
paiyate
def-ini-self
Belf.-Name=face
d= demo
|acese by hanee mathading,
rindlddemo.name
orcteted 6
detigltCself)2
Selt.name Jacl'
dzdenmoCs
print fe heme)