User:Shridhar Paudel/Lesson Plan 2: Difference between revisions

Jump to navigation Jump to search
no edit summary
(Created blank page)
 
No edit summary
 
Line 1: Line 1:
{| class="wikitable"
|Subject: Programming in C
|Date: 2080/10/24
|-
|Class: BICTE
|Period: 2<sup>nd</sup>
|-
|Semester: 1<sup>st</sup>
|Time: 10 minutes
|-
|Topic: Conditional statement in C
|
|}


= Specific Objectives: =
At the end of this topic the students will be able to:
a)   Understand the syntax of ''if'' statement
b)   Use of ''if'' statement in suitable situation
= Teaching Materials: =
Whiteboard, Marker, Computer
= Teaching Learning Activities: =
a)   At first, I will revise the topic which was taught last day within one minute.
b)   Then I will give the concept of ''if'' statement with syntax:
Syntax:       ''if (condition)''
''                   {''
''                   Block of statement 1;''
''                   }''
''                   else''
''                   {''
''                   Block of statement 2;''
''                   }''
c)    I will solve the following program and make students more clear.
Example: Write program in C that accepts any two numbers and display greater one.
                   #include<stdio.h>
                   #include<conio.h>
                   void main()
                   {
                   int a,b;
                   printf(“Enter any two numbers:”);
                   scanf(“%d %d”,&a,&b);
                   if(a>b)
                   {
                   printf(“%d is greater number”,a);
                   }
                   else
                   {
                   printf(“%d is greater number”,b);
                   }
getch();
                   }
= Evaluation: =
In the above discussed program, what will be the output when (a>b) will be replaced by (a<b)?

Navigation menu