Transcription of Programming in C: Basics
{{id}} {{{paragraph}}}
Programming in C: Programming in C: BasicsBasicsCS10001:CS10001: Programming & Data StructuresProgramming & Data StructuresDept. of CSE, IIT KGPP allab DasguptaPallab DasguptaProfessor, Dept. of Computer Sc. & Engg.,Professor, Dept. of Computer Sc. & Engg.,Indian Institute of Technology KharagpurIndian Institute of Technology KharagpurTypes of variableTypes of variable We must We must declare declare thethetype type of every variable we use in C. of every variable we use in C. Every variable has a Every variable has a typetype( ( intint) and a ) and a This prevents some bugs caused by spelling errors (misspelling This prevents some bugs caused by spelling errors (misspelling variable names).)
•• Several variables can be assigned the same value using multiple assignment operators. Dept. of CSE, IIT KGP a = b = c = 5; flag1 = flag2 = ‘y’; speed = flow = 0.0; Operators in Expressions Operators Dept. of CSE, IIT KGP Arithmetic Operators Relational Operators Logical Operators.
Domain:
Source:
Link to this page:
Please notify us if you found a problem with this document:
{{id}} {{{paragraph}}}