Entrance Announcement
MICTE 2080
2080 Magh 07
User:Shridhar Paudel/Lesson Plan 5: Difference between revisions
Blanked the page Tags: Blanking Visual edit |
No edit summary |
||
Line 1: | Line 1: | ||
{| class="wikitable" | |||
|Subject: Programming in C | |||
|Date: 2080/10/28 | |||
|- | |||
|Class: BICTE | |||
|Period: 2<sup>nd</sup> | |||
|- | |||
|Semester: 1<sup>st</sup> | |||
|Time: 10 minutes | |||
|- | |||
|Topic: Looping in C using ''do'' | |||
| | |||
|} | |||
= Specific Objectives: = | |||
At the end of this topic the students will be able to: | |||
a) Understand the syntax of ''do'' loop | |||
b) Use of ''do'' loop 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 ''do'' loop statement with syntax: | |||
Syntax: ''do'' | |||
'' {'' | |||
'' Block of statement;'' | |||
'' Increment/decrement;'' | |||
'' }'' | |||
'' while(condition);'' | |||
c) I will solve the following program and make students more clear. | |||
Example: Write program in C that display the numbers from 1 to 5 using ''do'' loop. | |||
#include<stdio.h> | |||
#include<conio.h> | |||
void main() | |||
{ | |||
int c=1; | |||
do | |||
{ | |||
printf(“%d\n”,c); | |||
c++; | |||
} | |||
while(c<=5); | |||
getch(); | |||
} | |||
= Evaluation: = | |||
If you give the condition ''(c<=10)'', then what it will execute? |
Latest revision as of 07:26, 11 February 2024
Subject: Programming in C | Date: 2080/10/28 |
Class: BICTE | Period: 2nd |
Semester: 1st | Time: 10 minutes |
Topic: Looping in C using do |
Specific Objectives:
At the end of this topic the students will be able to:
a) Understand the syntax of do loop
b) Use of do loop 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 do loop statement with syntax:
Syntax: do
{
Block of statement;
Increment/decrement;
}
while(condition);
c) I will solve the following program and make students more clear.
Example: Write program in C that display the numbers from 1 to 5 using do loop.
#include<stdio.h>
#include<conio.h>
void main()
{
int c=1;
do
{
printf(“%d\n”,c);
c++;
}
while(c<=5);
getch();
}
Evaluation:
If you give the condition (c<=10), then what it will execute?