0% found this document useful (0 votes)
0 views36 pages

C# Topic 2nd 3rd

The document discusses various programming concepts including data types, identifiers, comments, access modifiers, and operators. It explains how variables are categorized, the use of access modifiers to control visibility, and the importance of constructors in defining default values. Additionally, it touches on the structure of classes and methods, emphasizing encapsulation and the passing of parameters.

Uploaded by

wprathamesh539
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)
0 views36 pages

C# Topic 2nd 3rd

The document discusses various programming concepts including data types, identifiers, comments, access modifiers, and operators. It explains how variables are categorized, the use of access modifiers to control visibility, and the importance of constructors in defining default values. Additionally, it touches on the structure of classes and methods, emphasizing encapsulation and the passing of parameters.

Uploaded by

wprathamesh539
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/ 36
Data tupe and aia suicie Identifrer An identifier Commenty. Cen ee Some ot / - baal aif mee ai Wa ~ tad - Jentitipr N foun ——— fang ha a aS and “inde “tal Be = at is 5 Spates — 7 —Keyuard Ns “t likey! Slang like on Value _*0 Variable - Ke f S in +s mullijing tk ig used to Comment __more_thany” one lines. Generally a Aw used _to__Comment entire blocs af? code: i 5 * multiline 1 SqECEE Comment * tabi See Used — each: a a Ay and set mano at dhe apled 8 content fixed, values, that Cont aa alter duing ily 7 ! q an - vice . af _voriable = Fa progam where _g > Wiiahle oo cestible i Ow of Yhe_ Vanible ce vartabbly tape Can he divided into __calegorits pe clogs _tevel_ : —_ ving the variable i _O_class. ino Method _Can_be Qny__ wiht dass a cy Sent Back_level » Nese orale. genes \ dhe te tT nk Me vail fh ro i ai a declared - Thee | ecessite outside xe __|nap i Keyword Shak ce — of 0 ‘mesloer OF class _r datatype. Ihkde ave maint ued fo + “Access — Modifiers Access madifier aye Ah fine Me gccewsabilits Different ——Ocvess modifiers ore = publics gg ee bib ~ Wore acess iv qianked _4n_ entire —pragiam ie anchor mad Sac anabee = a at ‘al ‘which contatos the class G can 2 qaecess these members of types. Syntax public —_datatyge variable name »; Pilecled Beige 4 ' Here _daoss limited _to_4 ea ‘he member — ond type —of Ye a. a ee tees dhe abd + Contatnang— tthe class any wuinere yarable— | Sitios: _prieded —dotatype ) Boolean 5 byte: & default vo chor: > deraulls i » mal Ia eam a - defaul ue 4 “ iy ganked ae pink a2 bik sage ikege : tng eet i Actes ft bu ign ye 2 ? hada ~aue a sbyie_: Sbt__9 8 — ana wage ie ie - - plat wie a mie a a i nk! \ehik 4 ince mye ae “etal ude ig. eo a 7 a feence Tne : ape de ack fain the actual aia 1. \n uo ways Aa a Mhpe a \luey ike deine ty type “\ convaked poxinig, oh Aalue ot Wwotime Auge \aviable Anis ANA gnd- a) \e name z= Nalue simijoy__to__apjeck fy iN chek cheat tu ple__takes a ae nega _—_ dyna ¢_Ay : ‘pint at 4 \untinne pe 4 tye allows. je Assign—any Shing we wi able he _J J System. shri Ye__Wal on + type ‘yd Neral, Na, SUM SPO RATER Tel herrea Opuators mnhihematical — Coriakas + Odds Two _Nugroer Subsuack 954 ones Ties * gy del afetands / ide Hummuaters fan 4 Nd + increaue nae = dew ta Relational, Operator =~ Chott ay__fiok ak Aunomarators __ayeater: eahey yea Shon, Yet Conditicn, i} ony of Aastqniment x condition Rssiqnmne Operahor Assigns Value from Na gide ‘ to de ogeiakor ae dds va agevand Sa hs 7 Menate 2 Qie__Aisign ea AD \elk _ofierand. F to Veverte oprands cit ye Wen Logic — = Substiacl viahh operand amine Vee Qyuand ad —_atign Ne oulk_ ty: Copy he sn ‘pat operand apeiator Copied thy = Multiply qcvand ae tithes se puiand® pe oma A qn aul \eik of hos a _effeck of | ° 7= Qiwider he ay ” Xho rian 4 4 tnnit operator Yho L qs VO\We __jg__ Mave - \ef by Hay hut at of bts | y= at Wit 9 d-by {n¢ — ight operand __ — m W v ‘ + 5 $$ 5 Ayevand = 1 fonds. vilue iw me Vat awianment Vig oporands value is — taves Lee \elt__asiay eng ate tum — ch bits | == bythe oping (= ee BA - & = piwise and earal D i ala s eae VWOY OW nh onngy pul 1 jobyte convert ANE Ayge “Ap we i) ToDaleline © Convert She ge ay Adelie Auge te_deamal when we age scope A —\Conditiona\ it__Salement _\F Solement ig Te_sinaec) 0 nwented into qn —_-G ade ty be -& 1 it te : be methods “pret mere ung Tha ae Fiz Z 24 = wy OT Yo Te + xs) IPRS poy to SUTIN Coosa Ey ay Pan G ean a. payer yoTU i tb re SLaenent ubich ala +t foreach seed HE Cee PEPE Noop is used over Qementy dag oe eee heen semen ina Tal z Saket Saree — ue in “fayoard eased ( Law gor each \oop which iy ued ty | (num == rev) Console. writeline oC “numb a La “Palin vam 4 — a Wyte a progam to \yeat. between _* gwen ta int. styeay Console. ty 3 4 ie nia Pa pe Classe = new | Fm 4 Cenetinod Nena sm fossing«Povameler to. Meth net method.» with Ato pass the oe ee wy \hat__‘yoromebnel cag w default é yasoeles to_the meta na 0 ass New Storage vid each value parameds arame’ are We changes Model imdhed Some specifies, a side the method have no phic ory Tpueviah Wow 7” ane | Mo orgumen “ath ta abyeek genes c— ut Lith Wig gyeteences to a me Name mothed Name QQ lof 0 yawable when you pass aga ha esenty “that ave mathed you _Can__declare --Patameter. sig ve = | “A iekwnn __| returning —Gnly Console. Whiteline (“Cali or tuamgle 4.0) 4 ace ‘ Console. Whileline Ca), (past Wailtling _C “Cot, by sefearn (2); ramgle 2 (aya aM 7 Ni reentry (a, tal p 7 Console. Weikeline C” Call by teu); trample 2 Couk x, aityyo Ete Consul. rile Os nf “ opatuilt Waileline oxplain Passing _¢— — my a alt mE Sa - : ae a ing With Class {xample 4 . int ak Sy sine ~ ; 7 | class, and__ object I hass and ~ abjecl — 0 class ig user g —_ Hhach objects ore Create 2 Z onde oat Trine Tt A closs may Canta encapsulated, + gata ___wariab\e Gqnaticns dota _ hal met a ele —} fof dala ie ; a Tectonic 1 xa oka wining 3) Yah i z i declaration are _ enclose ; a Tp N taka ay ——~Oz20 5 3 ja EE (ode Wek Veale iN OA gyre Ms Wh Me Celle ks, properties 4 eu any type goo) fink ae yn be accessit\s ore, declared tn 4 Whe O¢Ceas. Ley hy She — ype ot the Contwuctar 7 \__Constiuctor ent) _|_dekault values. asa _cons\nactoy yaad ue which ore Enon gi at nat change Fut_thy Quvayares only —outlhs= ie Aya. are declared Os constants con int yam — vos oe ae gan ae doin Se square by 4 quart perimeler Cs) Yuimeler of Square fai Ges) Woke a pragiam Yo ete by. ar ‘enslanelenaay — —= Conghiuctor, np Per r song rad \ F Le ated find binary , octal, ding Upon ter [oy | sondau ule eae rem ah iin > Tige—of Cenc = fe pit ae eee | Feat ——delaulk -catvbiects for_ftow overs infance | A_defautt constiuchur Taw ven Lot the clas ty be. ne basa wublic —yoid Addifian as i___ 1 Ceabby one ine Cet ge che (A eetas p ‘mga a Seine aS Finaiese u Nd \ongey ‘ sh Clases Ane au MW 3 Sevan clu the—subaamredet fom the me Ie Called peal iv a ——class—Clauname— Kare class ‘ hol ke Avid Rane Shiny Daw i a a a, hi —— Fe agra foie seeeseU y——Torma in a “yale expen a, MAUL OAE para cdoibhe Xd , Main (shiny (ar)

You might also like