Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
3 views

Basics of Python Programming

The document discusses various programming concepts and syntax in Python, including data types, variables, constants, and operators. It also covers input/output operations and provides examples of arithmetic and bitwise operations. Additionally, it touches on the importance of proper naming conventions and the structure of Python code.

Uploaded by

sarofan698
Copyright
© © All Rights Reserved
0% found this document useful (0 votes)
3 views

Basics of Python Programming

The document discusses various programming concepts and syntax in Python, including data types, variables, constants, and operators. It also covers input/output operations and provides examples of arithmetic and bitwise operations. Additionally, it touches on the importance of proper naming conventions and the structure of Python code.

Uploaded by

sarofan698
Copyright
© © All Rights Reserved
You are on page 1/ 22
+ x “ Yotnien in _o ‘vig Juels Yate ond ape, his \ AP eos =t0 lis. cn do not srQuire ‘rernpiiation ' \\ sdk ine “Obie sOvientea Proweomnm ing + 1k “in “emnbondta within “Cor fe pre, [a re iv Ms — Hee agro Anads og powitn Yaak i er Gok Sypia!_and cay _ Wot cami ek cannte ucts ate Agenty = SCCADY fh unin x0 eee Xoaie wpsilt 0 ges us nendbaeanggNA wan Larter NASA om ‘Work Mow Aukomation 1: ‘ : — lolhich is wristn in Dynen Ws Aeenk-end Aon. Myeio woe Nueces. SAGs SVT eke 3.9.0 jx Wor lokek version of Python ae y Futare of © 2 Putnes Pao i fonquraoe is Ctl ant aetna el clewelopinenk, yptecs duutopmsn Eppa A cleublo orm unt’, s Saree E eee ee eee Rete tates Coase S with Pythan ran made — “Se Popaible Metaq nig e ign agen iheon ‘ The Aurore pcope ob Potro program og fan alsa ‘ne Oreditked buy Yaa Lon qarcte woo ke non’ Jnriped “Big, Dako! deen nology — so: Sqreous Troovg. is a koothiks and \i tattle + Networking in another +ield jn wo ho, oa brighten ACAD In hotune + Further development pn Pykhon Stas gea mm One oloo in prOUDA whith” will males Te Mone _ceanpaki ble ond kash prow sing. ‘Erowacoming Topics. Romment 2 (4) foment in Dython in taed 20 give thy Additional ne tutta injobim-abfan ab tha intro ohion or code. Siti Soa “pad ot a program ut nn: ‘tom nt canal be tatd 0a Wik Cemrnenk is specificds or oriten yp DADO. Live On Ae IA A lee I dhclient Sings Aina Carre nk a Exomolet t write a pregram be add 0 po prin’ dhe vend an Sim uy Mui tine Con ra eink 2 C iB untd to pin konns Anme specie One Maywords Oar 1 or -PULpose. es | Viner oda 3.5 apy words —_in Pyfin an . | ihe | oti [tse | tor olnie | bs Sepia ein 2 ite | aot | ta a : rel ast 7 | Unatty | ee Z ussrt async | await class ___giolo ae oe tio} __ AGiaeh Hiyiucss p _Tdenti Lf yin. A Deabiyien Wt ued 49 acer fy tne em Ne (Tada ti u) Tdrnbitin sn auld aluanays pk tnt unite ‘9 or underssore *—” Aol oued by} any cembinaion ch olphable or number [ Eatampine nailing namo NB numis bt =food = pigga’ y= ee E \ nl = Se any Spi hac a anonplaii-iummbieas S11 Genames Les: ye » Tdonh bien sagt etd Mot contain ony —blonk- po seu special choi citer,’ » mobi LAAN C, foen te i sa Kowivordd akeinot ned a Laxomplu. Trut=57 , Fale =O. ond- ings reas quatsa) = a emi ie Bou tat Tan NUMBER and number Ourw ia oo_in tone Pinan j» =: aemarHive. aL en + Numbers 52 numbers5 Af oe Nome=‘Foler’ A NAWE =" Joper’ Coie) Voriobl: ond Canstank: ios = x AVoxiables « Voxiob\e ore nothing, uk Ho tened roemory Loradinnd to Aton Yolen. Nadas Jhusucyn ew program re a 5 nan ¢ ik Examples mumibur= 59, nome=* Ryuga’ gorat =" Acoliistr™s OS = * pheonix’) ef ok ent Hye tg. a) prncih: enaser = 5 {we can assigne ent value js one Pe a oe oF Ame nt » é ="'th ¥, drink = “voniob)e at a dime eg Mloweld = g'se 0" cen cAted w bup'e py io done » first, Ssecan d2 third 3= gold" Silver’ i 7 24 An Constant one eciben in | Cashel Sed uns» ee a 5:30) ib RADIUS = 64000 Aue Wel. | fikerod Constant & Bch : +9 ——hivrnal on tae Rows Data given or Constant | (Sor more. iston ote pyno.-- ) Beis Type Dota Tr are sat ko aprcihy stich type ot Wolie ia aed io. a umd bt ad a Pyne fstspi tox A Saka Se Oh. sah aaah Lundy | Bins A die ae ‘de need not ko deckone tne dataty pr plik declaring o eget. Bs aur ly ote f L Oded "Cem men Ay Innit. Gi Aas NM mieaiel LONI, Nom eric. Tnt © 4k nalds “old Hoe _inseger Valse. oso Binaxy Octad hh holds “ pumbtrss with Aromat bs cantiineitiy in upto per a. complet Ai holds Con pla Hijabs Corals imag — “NO Yale) \ - tt sing A e PU Ha coercion of niumbus, alpha bate and chanackemds “” $i Aah a cose d weit 8? ao cette 2 ==: noam-num es D isttyen?s hechar: “@120" tah Wam-thar=" Hts \” a Nom-Num. char=" TI. gor 94°95 ¢ Drees ans / oe ae shak we Can dre. wilh Es aa aed £ Oneal | 9 O94 + Yoo or mon /sring it: to join fhe try Estee Grau", ste 2- “ mie somes print (Sart + sth) 4 ucky quresorne ‘Wc napitiions Sin una Aooaepeate 6. ah, Examples: sit = “hie\io” + I prin (Sir yt) — > Wito Hello Hells — Di Lists sh iso coll ection eh sam eh GOH iy, SY Ajamk ype af ekor. oN Picacho mun Se -Lramples lish = aot Stil ut Nishel=(L0 DOC Wb yao. 8) is \i i ini0/ctt ole Also OG tH HO Ok some or aahyouns Hypts + aM dork a 5; The tlemints are enclosed within round bracket Land 2 0 One inn + Olohe Jokotyme tt | | | | | | | | | | | | | | | | | | Seki 4y | iy dein encvosea dn aunity ‘roses ft cand — yp Sk win tor ane voli on My once. 1 Some OOe We Voni ole. dola- hype _conuension feroion. a xO! pan Faowing are doka® e eanversion fanckion inky , Woot), enmolex 1 bin), ockO nex C' dich stk) Honk; string bin, Oct, hex, bool = ai tour datokype con ‘inh! a bin-Ob 1 ock- Oo 1 hex = Ox int, string bool, bin, nek hex - tan be tonutnded ; ita 2 of int {oat bos! din Obs hex = tonvented to Cormple _ string, - \ i aN ny list » topple dick, set. String. OF ib only can sidened op Colne and heat Gh in d _closa'b pleaipninny in pafbon_dska okt 1a aaa ink oo} Hin sock converted into hey ; Pints hol bins be converted inks Ook 9). String , kuple icky sek © conuertedt IMO List Peat ype oon Te tonuinted inte dic cat nae ee wr nic ipa et discik ‘ Pixs _# 6) } ‘ple, y ay os + eer _An python it = Ustrd- Tt function “input & )_ js Used to input dota Aypiox aut (Uegt Eromole% nome = in put O) Lu Oddres = input 0 | AUN ber = int (input WW) « nd Dumbrd’= j E ier) Out put Optration + i yenitor ‘oy. Unig print Fontan. Suynkon.. print) ociWen in print 1) Ann chen in 0 as! Aw dorvaty pe writs in print unckion ton be yoRun Op _6ubput - J Enomple: —pint( Ware World”) print (Enter the nombo : ") ving How ave yeu ") prin Ae NY Bie ry LOD peter (orf Sis a cpm Plex oD Ly) ei Thin unaien is wad yas Formas te ig thi _jndex Syntax: oe oe Jui prin (“Yohi's a Sen of £13”: formartsom Wore) _ ‘nai Jatin in a Mama apane ak tt in iy ‘ it » ib o4= 04 i f 1 onint ("Do sikive wo: Y) fe aot pid Web woe tam pris Neg ahve Do. ") itnmetic 6 fe pees cei co UneA to pen Aono Spurakor | Read as M toning Exar ple + _| olus | Addition ‘npimtor used Sor | 32-51 AN ee wp Piesilve { | f= | ininus | Subtration optaknr used for [io-B=2 | Om harming Aubrration of koa “ Ot Agia numb tr Psi Shy Division Optrator used Lor Dryerming division of Quo ust mod Modulus Opetrotor std Aor division ond Kekirn fo yum odin dee yale Ay. 07 ethroulte | ony) Gskrish| untd tO Ap Be Odwee ol | = num ber peer slosh | Yor division and nara ti | =g Nae in nieqre every 3 J | untues ond esabiisp uebobion xii pr cum alee Shon opiator, shou Yhot lela! ae jon. gctater Yeon rag ‘opernndl Sess thon egal ke Opto or AB Oto is 2h Yen Gr syrah Yo pant opyond. dprratons onerato On Hf _cinsitn Onid | aning and ura d a+b is quivaln} to a oa+b adding signi Bide opurank (ko ote tt side O-= ss equiudlest bes = a-b sulira cling Tigit oprand yo Rb optrar All asst yomini ORtcasd Byned- to ObAL Ad Py Tait oy aaprerion to 0 vorinhle, | of)’ in equitislent te asa a= 0/b aX c o/=b is equivaleny $8 iv ich A Ao %= bd ty equivialynt to “a= 0% b mod diuiding Tighe oPtxond 2 Jeb ——- we ee ig) 0: and Jo pound) right opmand oil=b is tavivolens te a= all ey ao ok Leki operand > 7 tala Wax onus ip aabusenys efter run or | The wadue i comaicierta on Ealat Aperabar | Meaning and Gand b: Trae it Anon oftn ond " | Toure) otworwise als or Oop hy Palau iy bat eptrand ont t- Foie, ctreptorse’ “Trie not A i | Fone ik Tou i Meunbur : i ‘Tnese_ G: i ind Whrlnex tt ip seus ¢ en} Co) ‘Thest: ‘opemtor: ont untd to checke tilribher one Sj uoniahl, ih indendicny a0 ovens or net. OR. thi olOpuintany ost unt je! choc whee fine — Spying’ is Osh 6 same mums oration Ai), Thor Koni of . \ Tdandidy pk Ve _vitnen, Feuer ov de In Bid yy dniisia/ \ i AX opovand iy, ¥ . Paaning. t ci aib’ hawing Ame mary AGcatiwry ax “thor ch lo jonni |o ia not bs retonn Wee vor i : BE Her Os nay | ARUN Menno rep ie Jovovior 0, ook tn. 9 e fs Sieinas ts oath ection Mm chonacker, dw, ore bw SOtraWorn hak can purkirmed ory “Siring Bax di a ing’ E fh tonting DY Oo sl tontakena en’ udirts fein by 9 or : ih more Seng Z sale * Lp repo © dtd Yor ep’ ks Aiwle ip - He | Riva, Bpaiire! gee Set Cond 4 one considtned ax bik, Bihoise Bit wise optralny med snred so Penton wn SPthaty jwisck ons bit Binoy oh oh A vole. e { dn Yin} givens value” is Feat qb tenvinbtd into Bin P Ams in “Bimomy is pendintad whi tein con ¢ std do per eem Jowica\ ond 3. (boo GO € yi Bitsise amd = emul plicatic: mulKioliakien) eter a ond b. oD: Ritwise Or =) gddihon yy mM os au tlie Jototemy a ond bb. Ovb: ditwise: Loe = Absa << > Sloa7 4, werans make NOt has by ODA AAA ond AA BHO ak “star in} __ aperohot Bxomoles 9 (44 2)> pun rrssion Axum na Re OMN AIRS me GS bine C= Op, eke, taken LET oir Some i desis mn! Xevloutd sy Hatem oti os > Jas _artnonayrn PEMDAS: is urrhul ko runner ting 1) Parentn ests PO) And Hye me ps Bs ond ton lor "ae aie on Moe (ehh shih | right shit, Binuise ! rane a (aaare) Aijae, of Expression : apt is Thiet” ant Stkert “iy ors “of. Exprassion in @eoression ik iyo normal an tips on jn Nes Sonn ob brisan yt de Opuanda opumior Qpuran 2 a+b ony oh 0 a tg. ab Posttin Cupwabions ik iA a ipeession in Yor ons (Gpenond-1) (Opmand:2) Opwator Bic) “Sa orto? ‘pe

You might also like