Lec 1 - Introduction Basic Symbols and Variables
Lec 1 - Introduction Basic Symbols and Variables
Lecture 1
PROGRAMMING 1
1
Tasks
• NA • Lecture • Exercises
Presentation
Identify different
arithmetic and relational
operators used in
Differentiate programming
common data types
Differentiate the
types of variables
INPUT OUTPUT
PROCESS
FEEDBACK
Compiler
• transform the code into a machine language.
1
• What is the problem?
6
• What processing is needed to produce the output
7
• Where should the output go?
3xy 3*x*y
x2 + y2 (x * x) + (y * y) or x^2 + y^2
Destructive Constructive
variable variable
Variables that destroy or
change its value after
processing.
Variables that maintains its
value after processing.
This type of variable is
normally the temporary
storage of data during
processing.
5
510 === 10 10
AAA BB
B
After processing the instruction, the value of variable
During processing, variable A gets the value of variable B. A
Theseisare
nowtheequivalent
original values
to theofvalue
the variables beforeB.processing.
of the variable