0% found this document useful (0 votes)
26 views22 pages

PDS Komal Ma'am Assignment

PDS

Uploaded by

hettj149
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
0% found this document useful (0 votes)
26 views22 pages

PDS Komal Ma'am Assignment

PDS

Uploaded by

hettj149
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
You are on page 1/ 22
By weet re Baty“ Assignment" CC ——_|_as_inpus 210m ining In the finst sining ction the sia position. Ce xcimple sining =i = tetisinoa University" Sining-o =’ Technological Ouspua =" Craseutent Techmelagical Univensiy’s Sins input enien the finsd stning..” econd Sining et ease | the: econd ning ")) bn driC: Position 4 san 74 aiceetaa a Pains C'Resurtams saning.” 1 stops eae: the hesury = Hesuis) : i 2.1 Discuss 9 choriseionistics 26f/ se4: cind Dictionsoy st deter saritedaten in python:v6 Boot Danshun) i 1. Se4qe a) ~ Ac 'Se4 is/-e mnalicile | deer AMUeUHe Het cin amondoned Collection: of uinique jem —____|+ A_Se4 wwii "he sme pa 2 Bnockets’ sexy! ——Tt hen _simiten methods: seg lists; 4h eo nlt— differomce between jy 4cind! se4 ig = blisy i of inems.0 Hem Obj ecy : find claose 'veilyos cise: obiect hefononre —netfening ‘ta “lay Old ects > of diny Ape = cidd, edit’ on nemeve Hem, but as iti uumand ened =e “cannot -Slice- thie diction tuys t —|+ Dictionary = sil "be nepnesenied ith the cuncly Bnackeis:' Ckey waste ry my i dices Creep ri vetuey wey 2is'velues' } : =Noie: Key -vatae: cine: sepaneited by tolants ! eldded is mai preserved 2. Umique £ lemenisi- “Seis storie only unique elemenss. TL yoy ignored. 3. Musatoie ts paibnenatan : a = White: the Jeleme nits of’ crvgeanmuss be | __immutable (eq. no. s4oing's/4 upeisi, the | diseit sis: mutcle: you sean w_cidd-o%n semave | 4. NO“Daipticctey :! cenisicoy it ner they ate -ofensiased “@hen- you need. to ensune— ta -Catiectians of dis¥incds vetegn leis t SEtficions -Membership Te: xing Date = fe —I ; ra | 4 \ 7 = =Yeu can aise verdd-cy —nemoatie (4. discand ¢) POPC), cind cleaney 4a wmodify e4s. Chemeeieniistics: of Dictignunies —— 1 Key aioe periag pt a4 ALE i iqu md id maps =A dictionary igo coueetion of joy) +veilue 4o_o\_comnmerponding vatue, Keys “must he. S . . \ Immutcible (eq: Sinings, moi, 4uples), bus Be et > 2. Garderto Antares it . pletion =I python (3.4) cind Later dietianentien ? maintain the ena they stan sone, — 4 Ty_ecantion versians, they « 5 : 3. Efficient Lookup: eid eben pubis die skid ve, duane ce | ess 4orlotecy meting Lookups -imsentions and — deletions -of Key =\relue Jpaizis efficiens- 4. Mutable. 2 ab ='Dictioneviies: cine mutable’, meciming-you can |: edd ynomove, on change Key =Velaue -Polins after | ame dictionany —-isvenetted. | nein Ss. No Duplicate Keys te Bos = Eeich key ino dictianany: musi- be unique, TE YON ansign’ “ol neg: Valtie +0 an-ecisting Key | fy gil overmuite the -preirious »Veilae. Page No. Date q- common _Operncitions t- updeting veilues ¢dict Cnoyd = values cind eidding on ine moving Key~ vale ~patin (dicts pop ¢) om dei died Chey Dyes 2! bettvistoh . arti [g Diedion erty) Methods!: jhe meswods Hike Heys Gif yeldescr, nd dems ¢) emacs | eleeess don Royse, values 6n Key-velue Pains | Addisionany ,-gerer, setde faulttrrdand ii apdeiers |__pnovide _cidditional functionality fom manking | epith = dictionemien of oi on pans) ti bate uM = ir att. ; an a Aype.’: “Requlet” 4) >| From. collection ia a oy 7 lmpont: detent diet > +904 C betsien” (L397) ree aaa fe Yo}. get C hetgen C893) get C'ivpe”) none) Print (veilye) ___4-| Focptein fouswing sining function ith suitable + i 9 peer find, stind gepleice » ¢ > ae Lelonc) n ‘in the ~sining. Eos my.-sining =" Helle aontd” Osip adi 11 2. count (siibsining i= B |_ punpose » Reiunns the mo. of occunnences of er Subsining in the sining ~| Page No 3B. tidle ¢\: nwa aell oxide apes aRnamieesegctl aca, a + Logencane ” Eee AM a need cota eer pag | __Phint try. siming. title Cp» | ‘outpuse “Mena cond, python progeeamming" 4. Lowen): ee ee ae | semua mnyin caning wUiteto. aisnatd do Lomernrcse 2 , ping bemys st ning: loos eri t)1 venes ee ee av vita “teat lah” abi 5. Uppenes j—Punpase:. Canvernis alt characters of the stning to ippentene. | oct my~sihing="“Helta mantdy Phimatmy~ sining .uppert | __ouiput “Hex “HELLO wortn” | pPuripase t- Retutins the imdex of the fi G.find (subsining 1: __ ofthe Subsining in the sining ea? soca Pinte my 2 Anings find Clomid” 9) hin = Phimt Cmy— ining. find ¢" python”) Oreo ofthe “Subsining. in the sining. Reiuans -\ @ IF mot found 1 Bock. my = stoi A a = HET oi - 2 mond” poo Plat Cmy ~ j ing” % _ Si m1 4 ating Coxon ld") Ousiputr o¢ &- replace Cord, new) z 2 punpose + Repleices cill Sccumnenter of a Cold) mith ot “nee Substning (nec Ear my saning + “Helo contd” paint Cmy~stniing qe plaice (onl d*," python"y). ubstning ouapui: “Hello python” beng usigeln sat ~ | Rey fecuss10e5 of py thot 5. Tnsenpreted “Lemgareige 3. Gynian is ecunien io vead 4. open Sounce id |_¢. Huge crmount of cidditionei|_apen= Sous Ce ——§ = 30 ot Ley nemiienil. List JAN undndorted ~ cof ocsion | Ayiosidehed Colleciion fe Cement s:* of beAicyolues petins: icon i 2. Repnesentetion i calnely -byKicon fy. cafcely banter t) batt caith | (ee y= Welle: Petlz1s. dened 1+ [3, omdened* Dictionemy ty + Ita is man hemogneous [ttt is_mox: homageneos—— | destéa sisiuciuine > thett old emer Zinactine thet stone 2 imla single oto or mulliple Doesn't c1ilocs duplicate Keyl 3. Alles duplicate eloments ____4.| ty ect oe —aaes 4od_cismeng-cill ea | 3 can be eneested_sising— | sno dicted function. ty is mutable, its— keys |s. TH is maiable its me is [4. 7a cam be enectiod aging the lisit) fundion $4 etc 6 Not Allow Ll c Gs Alloa slicing > = e do A+ €nlist the feciunes of MMerielotlib: Sh Vewtiedy? of plote pate Supponts 1 mide acmge” of plot Types, including a 4 t isto — rl oo catstomizeiiion1- CE oiensive opiions fon = Cusiamirzing plod Pfenennetn ee alalalng aes Ne Te ea aa line siyle cimd mone S$ Inte gnevion « wet f ith : . 7— ' 1P}— oti a ee Jaimd corm be netted into vertious CrUT:! cippliceutions md web fneumewonts: are Page No. ——Date__ G. Tritoncietive plors- : lading plots im necl=time, = Ccim Seve plois in tuda £ = i $.Themin 9 ——_|_+ Includes pnedetined sivyies und themes, cimd —— —_|_Cillamns__cnecition of Cusiom siyies for consisient — ——_|+ plor ctesthe diese : Q. Com pritibilivy: Se eta, ee eee | res fon secimless developmem+ and visuatizetion los Eootensimilityss os exsiom plotting functions cand soa lt | A gneiph is «a coilection of noder-tomnocted -by meinont u L > Page No. tl ef aya “ | ye (Caras aid | pide ptostoo.y mmunxen eo! od plowing the gnuph 1 | pli. title ¢' simple Nine _Crzeipta’s tH Adding tiller | Pls. oo Lebel Cine-cincis'? lcibe) iE pli. ylebet Cy erois's Pil. shot? # displaying the gap — -9| Hom to Soire quae so disk) acp tet — ~ [ta Seve ot guaph to dist im_python , 40" noni tect Yinony. “This function eillanes you +0 cannon figune 40 a file in vertious fosmedse ___| pli. clase Date }——_1™ Pont —smeitplot lilo, py pias cis prt ss = = Ht Doda fon: ploiting: . dos Cio seaysd Y= [9,3,s, 4,07 st ploiing tne igheph. Pitip iat (oo, 1, yigyeen =o") H# Adding ditles avd: Lebers- pii-dithe ¢* simple / lime gtrciph’s Pit. ocleihel (*oe+ cseis'> PLL. ylahol (y= escista - H See - the -gnaph + dist sd cA | pit. scive fig Cline. grap. prg’) # Suve the gnaph 4o/dist ano PDE tile Pit Sewefig Cline. gnaph.Pdf'> tt Rap irena com Rane CERIN Ine! # ple. Shoes 3" PNtr file # close the plot legend explain symbols icaisns—on_tine helping dissigunisn -beimeen dittenent | viemens $0 qutickty insenpriet Comp lese im fommatic Leloets- y ae vre} onvginians” jartprenctiat 1 )-2reivea Aunotetians:: i IS teria prmnpssatinn Soity witquseoee ee’ Poinis om +nends, | pnoviding emplenedions o% emphasizing! sigmiticamt | desinils, they eaasiice™ ahtnlas sense iott mes le Page No. —— —eiuan ey 3] Mili penn pageant equence —— int cinput t!énten the newer denmaery) bel if mco;- i /phina (plocne -enten ici positive integer") ——— else: Puins (P" Siboneicei sequence apte {ny 4enms:") Ot pad ts 2 Eniet the nao of 4oims 14 a i filonicci equente apts 4 dernm Co, 1,1,213,8, «4 — ytSmput from the sisen cmd counts the noof }__Wamoels in iy \ As Livesets =“ eigu Aetou’ - : ! _—_}+—Couns = 9 fon chan in impitt. si ning + ) if schein in vame! coump +e Heiunn Count -inpus = “gender Sining") ___ | vomel-~ count = Couns- vowets Cais en. input) —___ ouipusy + Enien Aning + Henao, Hee ane you [Fever] St Vale la | Compete Lisacend: Tuple si. Coopletinn -yeutiou¢—— ame thads of list - feaiunes list oot Tupile (fee eee | _____— Mudaloitisy! Muelle Tmmutterlo fe ——________ | synianc| | creciied sing C4 Cnecdied a ing O) Taples cine fisced im —___ Ee Liste emendynarnic: 9 cind cain gio! slinink | | size after schnectiien- _ Lpenfonmelred Stiguily slosion due to” dymemic nesizing | leasten dae to immuicibility | Page No. T 4. temove (y+ MY=lis4. ¢ send(e3 a4 f Outputs C155 ,3.47 Tmsents an element cit espe ified __| Exot my list = C1,9,47 tmy list simsert (2.3) ourpttt + C1,9,.3.47 3: Insert toy Remove: ourputrt (1,3,27 FT | {fied _indesc. if No index is provided , pC Sp CE clnd weiumns the tens element. Vi nemove Page No. Date foc \- my-Vst= (1,231 amy lisa. pap Cd ourpur (1,21 coohieht foots my-lisa = (12,31 my alist clown ey ute C4 *" way) bee a hiet st qt yi: Rerunns the indese of the fins’ Occunnence= of aipecitied i vellue.+ Eoct myalist= C2139 omy alist indesc co 20" pods tre ahrey ourputie t a pain _ =| ta ig timondoned , mutetble cmd imdeoced by tevs, — | qwich ene umique, | You can change, cidd of nemave items cfier «ne dictignemy is created |_Dictionany methods: getcr, Keyser, velueser, — | tems cr, aipdeite cs, Roper, cleaier, det, — thee =| A dictionany i5 cnectied toy piecing ot comme: | Spaneied Sequence of Key: Value pens indside— Date ! gC eee ee lene [Pee eee : creating a dicti ionuny to stone in Tadeny fo. abe | saudonset am cibout I — | wn nw ’ sime":" John ~~ Pamala ve uv vy é Displaying: alley primi Cstident.weys cy 1! fal \ ol \ my sat ' 5 ie “a enioet” R . ee ; . tp final dictionesty 1 ve te {siudent) ‘ ‘r92, ‘cepa 3.64 — o name’ ‘ohn’, ‘“uge = . ,

You might also like