0% found this document useful (0 votes)
30 views14 pages

Python Unit 4

Python notes

Uploaded by

thanks khan
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)
30 views14 pages

Python Unit 4

Python notes

Uploaded by

thanks khan
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
Unik 4 ed “| caepain 4. pete oy ile ofistaition uit easumple: opent>* Python har built to. aun chien. nent te open a _agles Wl ihich accep 2 ents, +le name ¢ acess mode in which ile is accessed. The _ __4pnckton seeluxod a fle ebject which mn Bacal ae paath_eaal Sa ea : , : - a cx: Hle = cpen (" rn-fle taek ns i ee Bar Beads: Thin er Heidt Bes mee Ale a Sane Pe | This Yuna" ebusen& (An) poe new line: Once the — aes! 0 hele Vines completed, we qetowhole empby | a ia uit ned pet eaake) f tell onethods-_ ch i lem: eiBle = eres Sabo. tach") Bie} pink gle. Si tie ald 3. [asthe 02: oe ies Putlnnn Peis. pupae Ohare a ty weite oa alring o lytes aoe cee __This +unchen peers ano. that & Aine ete data absted in. a_aingle. wigite cal) ere: le = open C'my ile tek, Yun). pad. 2a content= Ele uxrite (ello Werld') pink (content) ae 4 | dered: Tt is tmp. tn close le offer udiing ther so release aystem reseurced_¢ ensure data iaheg iti: f2e: File = open rey ple Cony Ale brett, 9) AN het) 7 ea [Link]) o_O 3 feisty teat se Ei Binary fle. ndiclty lyn '1na Toe alt ga i asa eackension _|. Teaek_ file. eackenfien is — tae. 2: a ny We _onebe aaron decured bon teact File 4. ple data can't “3. “Tepeboa ale elects can be he o eal nead bya natmal enaily seed by a adtinal ded Yr ERVe hadi Vat 4. Steres dada in the Same 4: < PEG wey as Absred inthe. aad UNICODE Chaar -_ meme: =. 5+ |INot ne initial TS pathy eltbel uta tecet editpr. a tile in \roth seadinn ard witli e+" TA opens | mode ia eae: Hle= ppenl'aample- 4ile- tack! et content = ye Ble. seead () - | pink Ceontent) F — 4 | Bile. wete C\n Th is added teack: ) 2 i Sle. dlosec) 4 ict wll, a - — 6. [3Yb" Opens a Ale in_binudy mode (io cade cs images, | -eace +iles) : ae [een Tt eens a tle in heart mode =) list 4 eveplain any 4 File azceds minded sed ia or Brose . = ||. be = Read ane z seeeeenene FF olla. Sw! = lsite mode 2 ay ald Ls 2 “t= Read ¢ Inxite mode a ple = Ppapend ode — nt ged = : niase ans Amman endl eats bese Rie operabions sine Es -pathen |e! 2 Read mode: C4. es seeding ae 7 eae: File = een CAoumple ele tack’ .' x!) ae content = File. xead ees ee ollie _iqiink Leantenk) mio baaant lhe L ie ig Waldo ees cht eee ie hall I dh on ee 2 + spilevtrek! dot | fite. usethe Caddtienal dade) —————___ __ File close oy os Ss [ e. close ia Fi ORb open a gle oh send € we ly ode eee cea nt sy | "nh ee 13 gain lines) { | File. clerecd exe: File : open(' beach le Ble umite trie aa mepie —— = File. derecD eR inec: Thin nation ibn a oe exe: File = open (‘ony file tock!) Sile. catidheao ». Sie. derserd ® yar? to open bina file fet cl ee = open the let. _unah te ata ——— a Ble = open = Fle. xead pink Ubinas dates Pelee che) Bleed adel | jffp fp fp} fp top dd bt bP bk Pb ft tt Wsdke_¢_eneplain pytoan piegean ts Uhalsode use \: Seek): aeekOd cietape Row s . i_uded Bay l Iieck — ee an ate): belly pinchion in used to get aetined) petsitien jee gle ebjeck. By file chieck we _enean classmate, are. wshliibara lain: bo copy. Thecdnn ben op ie Lune) 4ple i into anotnet:. Open ee SY teuudhich. hel boeabens : afte Abseed ond 24 3A which content will be wried- wee Pica RS * 3 Hh = epen C Firs asieaeet ste) Fo = wen (Second. treh', Sat!) = lea: F# tead the content tees Pepe es Spee Meet aii. «lr sie ea Fo. mec) -

You might also like