[go: up one dir, main page]

0% found this document useful (0 votes)
15 views5 pages

13-03-Session 1 C

The document discusses the basics of 1D programming including data types, variables, operators, input/output functions, and program structure. It covers key concepts like declarations, arithmetic operations, comments, and the main function. Programming concepts are explained through examples in code snippets.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
15 views5 pages

13-03-Session 1 C

The document discusses the basics of 1D programming including data types, variables, operators, input/output functions, and program structure. It covers key concepts like declarations, arithmetic operations, comments, and the main function. Programming concepts are explained through examples in code snippets.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

1D

3 323

(By Dennis Ritcue)


s WHAT Is? INTERPRETER VsComeILGR
Shstallechen voawns collethm (DEzecates codle tine
Twsu th ons OEeates Cewple
BLine Code o mee

RCis mot objec erieuuted Eos to dehect ewor


o r det chen
St is
proceduwyal lanauae. T meaua it otfticlE
ve phoat en bal t bappeuing Time tating faper aunol for
PTO-uger
raHhe o i dn a bemnners
Cworks on AsCu values(A00 UNICODE
DESIGN METHOD
To KENS CLexial Lunde
Top bon otm upl
werds : {Reterved wods
0Key
Pyteon C32 in nuwbe)
9deifius LtenasSaune
Real life eg: Ater siorhw Bor roahmo cUTeima
Dcne a l
Chon
tukjA, we wi rri wil

pre-re u i t e theu w 20ytes (Twpo Ctt)


the tin4d e e n h a l
As python bov
Floa Artes VsCode)
Coo dAmre glont
ebjwbs 1
Preolefined
hane is tpecifit TO oY i
A a t t main ol tn 0rl
CAlld main tt inithed when
nally all fns ove
ho lin iK
Cthere is meting calleol hring We meed anker en wi
bo
Areu ho
Se cordb data data Type Aretheprocesor)|tCIAle)
Pimau C
doa bype
Run AM loderreLinker
PROGRAM CYCLE (S Dev. Ccle) S de Cele
O Geade the Sowce file
Compi l Binau h
STROCTORE D£ A C PROGRAM
0+fncuude <stdio.h (preproceD Lin)
Atter tompiah vn ileis prepeuecd liwt main ) inlpeuhes the Tean
Buut His obi hle tant wed olivecH dat tptmain () fm
b) n 'C we dont wse
To e a t t a bloc vakhe
Ace ( Primt ) unchon's backeno
Code is writen inc
we Y Leveytinaide } oill be
b
u s yhot
exetuhed uNdR moin
olb Ale dotne
e) No Indewtainn hecea
to do wi pt)
at hay ca be wed dirtuhy
Declanahion shatemeut apYint Enter a nuoer )
mt o10,b 2 3 We Ca omimm ap
tAays uat n e t ) or smia
loat C lo-O, ol-23 wel a
wat dehme
b) for prinHmg vadiaksles
thon d the value
have a=|O int
Nome o dentherTules Eawe
ourne printfC" 7d", a)
pintng daa Hfp
( mt b- a 1D, ael; X t oa is mtel betoreauigne
hen
i n t 0= b=t-d- 10, X (ue also b is wed Note: Data Be s onuy provided
ted
mimebA dehni vadue e an iclentifer is prin
chon tokmeut laking tuput3(scanf o)
waeel to cleoa tNe output
A)clrscr O SOneem ame amollny nD s o uuat
te
C e a c h U n ehames
AcHon Statement ( e n wnte
Ound then
ond wnte CauNon
Sntax: Scan d " , Lr)
allbuyopand
bund
LDCAh On SpeuFer
2more han ome Scanf))
CaLukion|ways

declonahon Statement
i wed we must u a
Pritf) Here in Cprut4) oloosut he leuutea
wOnt to uh (stdin)
tselt ves n So iwe
ine we must gve t expliuty.
Chanye
AeUAe qetch.t) To helol he Screen
to ee eP 2
bz en ]ftoat]
Wae R n 6: O i wneol lo tel n t) s exaiuty bype tapked a
the IC upliuty ype Cated aled coersiom
ds that pro m
oTun Suceehduy otheuise D would S o dvimg a ome 1S eouan
mot b eurn@d
C WAre A, m tus
Majn& 8ho tall main (? Ano- 0
int i cawt be a loahng value
DELIMITER :ach line maat be Hemminated fLoat b t Tust be int' to ftoat it
wfth temi tolonG) demoted o int 31

b 30 b)b cawt be int Sotoint


CODE SNIPPETS AND CONCEPTS gets romoted ho foak m30 01

L t a= 6
ASC VALUE OF k a
printf , a)j(A
print7.d',a) 6S
6 6NA1+b+0 b -
2

inty (5ineen
b e i o u ei n t e g e n . )

Nohe Singe tine Comment


Htoat 7
Multi ine tommeut/*
OfRATORS uway Bina,Teaa UNDERSTANDING SINGSTACK
("hd 1.d 7.d" ,att,+ta)
reaui res 1,2,3 openands rptth vely Print STACK
Note Hhere ie no

om ma 7
UoA Single ObuQnd)
a) he increment loakinorement Obenar Jet inihally a=5
R i t o e t evaluahion
+
Jut t pre inc opeato
So Value tesl to
6 uen amiqned
value (6)
2wd post| int. opeauor,so
i
to 7
firat Oncremeuwkt firs Anned min to hen ed Current

the 0mme
men hcremenkec
So t will &hond tue
3vol i
Value o

8 Nout pep he Stack valuuês : o 766


t+
++
Auothec t
printftt ) pri'mf C3 Print 7.ol 1.d Y.ol, + + , 7,1++ Lut =5
,8 uO froqrams (D:/c-Sauo
STHEK
13-03-23)
lolp-9eOSum &t bigit
1 s irst intremenie Let ws C.5 foqraws)
to ounol Hhen
b) As Maules
o)8T888 Sal
n ut blotk 5 is aiamed
Cir 1Pett )Em tmj
then fel to 61 e) farhenhett o Celcnus
mere wmekeo to
1 Rewere mumber

You might also like