CHAPTER 4 CONDITIONAL CONTROL STRUCTURE…
4.1 Control Structure …
4.1.1 Control Statement…
4.1.2 Conditional Statement …
4.1.3 Structure of IF Statement …
4.1.4 Use of IF Statement…
4.1.5 Structure of IF-ELSE Statement…
4.1.6 Use of IF-ELSE Statement …
4.1.7 Structure of ELSE-IF Statement…
4.1.8 Use of ELSE-IF Statement …
4.1.9 Switch Statement…
4.1.10 Nested Selection Structure…
Class 10th Computer Chapter 04 PDF notes download
Chapter 04
CONDITIONAL CONTROL STRUCTURE
After completing this lesson, you will
be able to:
• Define a control statement
• Define a conditional statement
• Know the structure and use of if statement
• Know the structure and use of if-else statement
• Know the structure and use of else-if statement.
• Know the structure and use of switch statement.
• Differentiate among all the selection structures
• * Write codes for flowcharts discussed in Unit 1
Reading
UNIT INTRODUCTION
In programming, it is required to make choices and decisions based on conditions. It
is important to know how to program the computer to implement choices and decisions.
Programming languages provide control structures to achieve this. In this unit, students will
learn if, if-else, else-if and switch statements that implement control structure in C
language programs.
{
}
Key Points
• In a programming language, a control statement is an instruction which determines the
sequence of execution of other statements in a program.
• A conditional statements is an instruction in a programming languag that contain a
condition based on which flow of execution of program statements is controlled.
• The if statements is a control statement. When it is executeds, the condition is evaluateds. If
it is true then the block of statement within the braces will be executed otherwise control
will be transferred to the next statement.
• The if-else statement is a control statements. When it is executeds, the conditions is
evaluated. If it is true thenphysics chapter 11 numerical solutions, physics chapter 11 numerical solutions for class 10, physics chapter 11 numerical solutions for class 10 all chapters, physics chapter 11 numerical solutions physics chapter 11 numerical solutions, physics chapter 11 numerical solutions for class 10, physics chapter 11 numerical solutions for class 10 all chapters, physics chapter 11 numerical solutions for class 10 english medium, Physics chapter notes for class 10 chapter 11, Physics numericals for class 10 chaptephysics chapter 11 numerical solutions, physics chapter 11 numerical solutions for class 10, physics chapter 11 numerical solutions for class 10 all chapters, physics chapter 11 numerical solutions for class 10 english medium, Physics chapter notes for class 10 chapter 11, Physics numericals for class 10 chapter-by-chapter, Physics numericals for class 10 for all boards, Physics chapter notes for class 10 chapter 11, 10th grade online physics numerical solutions chapter 11 of physics numerical solutions in pdf 10th grade physics numerical download in pdf, chapter 11 of the physics numerical book, download numerical in pdf, Download-easy notes numerical, download-easy notes pdf,Download-easy notes notes, download-easy notes,
r-by-chapter, Physics numericals for class 10 for all boards, Physics chapter notes for class 10 chapter 11, 10th grade online physics numerical solutions chapter 11 of physics numerical solutions in pdf 10th grade physics numerical download in pdf, chapter 11 of the physics numerical book, download numerical in pdf, Download-easy notes numerical, download-easy notes pdf,Download-easy notes notes, download-easy notes,
for class 10 english medium, Physics chapter notes for class 10 chapter 11, Physics numericals for class 10 chapter-by-chapter, Physics numericals for class 10 for all boards, Physics chapter notes for class 10 chapter 11, 10th grade online physics numerical solutions chapter 11 of physics numerical solutions in pdf 10th grade physics numerical download in pdf, chapter 11 of the physics numerical book, download numerical in pdf, Download-easy notes numerical, download-easy notes pdf,Download-easy notes notes, download-easy notes,
the block of statements following if will be executed otherwise
the block of statements following else will be executed.
• The if-else-if statement is a control statement. When it is executed, the first condition is
evaluated. If it is true then the block of statements following if will be executed. It the
condition is false then the second condition after else if will be evaluated. If it is true, then
the block of statements following else if will be executed. If any condition is true the block
of statements following that else if will be executed. If none of the conditions is true then
the block of statements following else will be executed automatically if it exists otherwise
the control will be transferred to the next statement.
• A selection structure within another selection structure is known as nested selection structure.