TFG - Basics of Coding Session 1 & 2
TFG - Basics of Coding Session 1 & 2
BASICS OF CODING
Importance:
● An algorithm is used everywhere, we also use it in
our daily lives.
● They organize thought and action (computational
thinking)
● A computer program is an implemented algorithm
EXAMPLES OF ALGORITHM
1. Pronunciation: Sequence
2. Can someone explain the concept of Sequence?
3. What example did we use?
3. What is a LOOP?
● A loop is:
○ a programming structure that repeats a
sequence of instructions until a specific
condition is met.
1. Pronunciation: Loop
2. Can someone explain the concept of
Loop?
3. What example did we use?
THANK YOU
Session 2
4. DECOMPOSITION
4+3=7
(Remember input -
output?)
Quiz/ Revise
1.Pronunciation: Decomposition
2.Can someone explain the concept of
Decomposition?
3.What example did we use?
5. BRANCHING
Branching is a basic concept in computer
science. It means an instruction that tells a
computer to begin executing a different part of a
program rather than executing statements
one-by-one.
Common branching statements include break ,
continue , return, etc.
EXAMPLES OF BRANCHING
REAL LIFE EXAMPLE OF BRANCHING
This is branching - You have two different options
1. Pronunciation: Branching
2. Can someone explain the concept of Branching?
3. What example did we use?
TECHNICAL EXAMPLE OF BRANCHING
Number1 = 4
Number2 = 3
if addition:
4 + 3 = 7
if multiplication:
4 x 3 = 12
6. DEBUG
Debugging is the process of detecting
and removing of existing and potential
errors (also called as 'bugs') in a code
that can cause it to behave unexpectedly
or crash.