<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Simple programs | Student Projects</title>
	<atom:link href="https://studentprojects.in/category/software-development/c-tutorials/c/simple/feed/" rel="self" type="application/rss+xml" />
	<link>https://studentprojects.in</link>
	<description>Microcontroller projects, Circuit Diagrams, Project Ideas</description>
	<lastBuildDate>Wed, 17 Apr 2013 09:25:59 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.1.7</generator>
	<item>
		<title>First In First Out Page Replacement Algorithm</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/simple/first-in-first-out-page-replacement-algorithm/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/simple/first-in-first-out-page-replacement-algorithm/#comments</comments>
		
		<dc:creator><![CDATA[Arun]]></dc:creator>
		<pubDate>Wed, 17 Apr 2013 09:25:03 +0000</pubDate>
				<category><![CDATA[Simple programs]]></category>
		<category><![CDATA[FIFO]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=4035</guid>

					<description><![CDATA[<p>C program for First In First Out Page Replacement Algorithm #include "stdio.h" int fr[3]; void main() { void display(); int i,j,page[12]={2,3,2,1,5,2,4,5,3,2,5,2}; int flag1=0,flag2=0,pf=0,frsize=3,top=0; for(i=0;i</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/first-in-first-out-page-replacement-algorithm/">First In First Out Page Replacement Algorithm</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>C program for First In First Out Page Replacement Algorithm</p>
<pre lang="C" line="1">
#include "stdio.h"
int fr[3];

void main()
{
	void display();
	int i,j,page[12]={2,3,2,1,5,2,4,5,3,2,5,2};
	int flag1=0,flag2=0,pf=0,frsize=3,top=0;
	for(i=0;i<3;i++)
	{
		fr[i]=-1;
	}
	for(j=0;j<12;j++)
	{
		flag1=0;
		flag2=0;
		for(i=0;i<12;i++)
		{
			if(fr[i]==page[j])
			{
				flag1=1;
				flag2=1;
				break;
			}
		}
		if(flag1==0)
		{
			for(i=0;i=frsize)
				top=0;
		}
		display();
	}
	printf("Number of page faults : %d ",pf);
	getch();
}
void display()
{
	int i;
	printf("\n");
	for(i=0;i<3;i++)
		printf("%d\t",fr[i]);
}
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/first-in-first-out-page-replacement-algorithm/">First In First Out Page Replacement Algorithm</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://studentprojects.in/software-development/c-tutorials/c/simple/first-in-first-out-page-replacement-algorithm/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
			</item>
		<item>
		<title>Program to calculate a simple interest</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/simple/program-calculate-simple-interest/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/simple/program-calculate-simple-interest/#comments</comments>
		
		<dc:creator><![CDATA[Chitra]]></dc:creator>
		<pubDate>Mon, 17 Oct 2011 10:14:53 +0000</pubDate>
				<category><![CDATA[Simple programs]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=2264</guid>

					<description><![CDATA[<p>Here is the program to calculate a simple interest</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-calculate-simple-interest/">Program to calculate a simple interest</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Here is the program to calculate a simple interest</p>
<pre lang="c" escaped="true" line="1">
#include "stdio.h"
#include "conio.h"

void main()
{
  float principal,rate,time;
  float simpleInterest;
  printf("\nEnter the principal amount ");
  scanf("%f",&amp;principal);
  printf("\nEnter the rate of interest ");
  scanf("%f",&amp;rate);
  printf("\nEnter the time duration ");
  scanf("%f",&amp;time);
  simpleInterest=(principal*rate*time)/100;
  printf("\nThe simple interest is %f",simpleInterest);
getch();
}
</pre>
<p><strong>Output:</strong></p>
<pre lang="c" escaped="true">
Enter the principal amount 50000
Enter the rate of interest 5
Enter the time duration 2

The simple interest is 5000
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-calculate-simple-interest/">Program to calculate a simple interest</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://studentprojects.in/software-development/c-tutorials/c/simple/program-calculate-simple-interest/feed/</wfw:commentRss>
			<slash:comments>3</slash:comments>
		
		
			</item>
		<item>
		<title>Program to calculates the area of a rectangle</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/simple/program-calculates-area-rectangle/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/simple/program-calculates-area-rectangle/#comments</comments>
		
		<dc:creator><![CDATA[Chitra]]></dc:creator>
		<pubDate>Mon, 17 Oct 2011 08:59:20 +0000</pubDate>
				<category><![CDATA[Simple programs]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=2262</guid>

					<description><![CDATA[<p>Here is the program to calculates the area of a rectangle,</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-calculates-area-rectangle/">Program to calculates the area of a rectangle</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Here is the program to calculates the area of a rectangle,</p>
<pre lang="c" escaped="true" line="1">
#include "stdio.h"
#include "conio.h"

void main()
{
  int w,h;
  int area;
  printf("\nEnter the width of the rectangle ");
  scanf("%d",&amp;w);
  printf("\nEnter the height of the rectangle ");
  scanf("%d",&amp;h);
  area=w*h;
  printf("\nThe area of a rectangle is %d",area);
getch();
}
</pre>
<p><strong>Output:</strong></p>
<pre lang="c" escaped="true">
Enter the width of the rectangle 8

Enter the height of the rectangle 6

The area of a rectangle is 48
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-calculates-area-rectangle/">Program to calculates the area of a rectangle</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://studentprojects.in/software-development/c-tutorials/c/simple/program-calculates-area-rectangle/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
		<item>
		<title>Program to accept five numbers and display the sum of even numbers and product of odd numbers</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/simple/program-accept-numbers-display-sum-numbers-product-odd-numbers/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/simple/program-accept-numbers-display-sum-numbers-product-odd-numbers/#comments</comments>
		
		<dc:creator><![CDATA[Chitra]]></dc:creator>
		<pubDate>Fri, 14 Oct 2011 10:40:47 +0000</pubDate>
				<category><![CDATA[Simple programs]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=2259</guid>

					<description><![CDATA[<p>Here is the program which accepts five numbers and display the sum of even numbers and product of odd numbers.</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-accept-numbers-display-sum-numbers-product-odd-numbers/">Program to accept five numbers and display the sum of even numbers and product of odd numbers</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Here is the program which accepts five numbers and display the sum of even numbers and product of odd numbers.</p>
<pre lang="c" escaped="true" line="c">
#include "conio.h"
#include "stdio.h"

void main()
{
  int n,sum=0,mul=1,i;
  printf("\nEnter numbers :\n");
  for(i=0;i&lt;5;i++)
  {
  scanf(&quot;%d&quot;,&amp;n);
  if(n%2==0)
    sum=sum+n;
  else
    mul=mul*n;
  }
  printf(&quot;\nThe sum of even numbers is : %d&quot;,sum);
  printf(&quot;\nThe multiplication of odd numbers is : %d&quot;,mul);
getch();
}
</pre>
<p><strong>Output:</strong></p>
<pre lang="c" escaped="true">
Enter numbers :
4
7
18
23
19

The sum of even numbers is : 22
The multiplication of odd numbers is : 3059
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-accept-numbers-display-sum-numbers-product-odd-numbers/">Program to accept five numbers and display the sum of even numbers and product of odd numbers</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://studentprojects.in/software-development/c-tutorials/c/simple/program-accept-numbers-display-sum-numbers-product-odd-numbers/feed/</wfw:commentRss>
			<slash:comments>3</slash:comments>
		
		
			</item>
		<item>
		<title>Program to check the occurence of digit in a given number</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/simple/program-check-occurence-digit-number/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/simple/program-check-occurence-digit-number/#comments</comments>
		
		<dc:creator><![CDATA[Chitra]]></dc:creator>
		<pubDate>Fri, 14 Oct 2011 10:34:46 +0000</pubDate>
				<category><![CDATA[Simple programs]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=2257</guid>

					<description><![CDATA[<p>This program checks the occurrence of digit 5 in a given number.</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-check-occurence-digit-number/">Program to check the occurence of digit in a given number</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>This program checks the occurrence of digit 5 in a given number.</p>
<pre lang="c" escaped="true" line="1"> 
#include "conio.h"
#include "stdio.h"

void main()
{
  int num,i,n,k;
  printf("\nEnter a number : ");
  scanf("%d",&amp;num);
  n=num;
  i=0;
  while(n!=0)
  {
  k=n%10;
  n=n/10;
  if(k==5)
  {
  i++;
  }
  }
  printf("\nThe occurrence of 5 is %d times",i);
getch();
}
</pre>
<p><strong>Output:</strong></p>
<pre lang="c" escaped="true">
Enter a number : 21353
The occurrence of 5 is 1 times
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-check-occurence-digit-number/">Program to check the occurence of digit in a given number</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://studentprojects.in/software-development/c-tutorials/c/simple/program-check-occurence-digit-number/feed/</wfw:commentRss>
			<slash:comments>5</slash:comments>
		
		
			</item>
		<item>
		<title>Program to find out the sum of first n numbers</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/simple/program-find-sum-numbers/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/simple/program-find-sum-numbers/#respond</comments>
		
		<dc:creator><![CDATA[Chitra]]></dc:creator>
		<pubDate>Fri, 14 Oct 2011 10:25:54 +0000</pubDate>
				<category><![CDATA[Simple programs]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=2255</guid>

					<description><![CDATA[<p>Here is the program to find out the sum of first n numbers.</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-find-sum-numbers/">Program to find out the sum of first n numbers</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Here is the program to find out the sum of first n numbers.</p>
<pre lang="c" line="1">
#include "conio.h"
#include "stdio.h"

void main()
{
  int i=0,num,sum=0;
clrscr();  printf("\nEnter a number : ");
  scanf("%d",&amp;num);
  for(;i&lt;num;i++)
  {
  sum=sum+i;
  }
  printf(&quot;\n The sum of numbers = %d&quot;,sum);
getch();
}
</pre>
<p><strong>Output:</strong></p>
<pre lang="c" escaped="true">
Enter a number : 15

 The sum of numbers = 105
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-find-sum-numbers/">Program to find out the sum of first n numbers</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://studentprojects.in/software-development/c-tutorials/c/simple/program-find-sum-numbers/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Program to generate a table of a given input number</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/simple/program-generate-table-input-number/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/simple/program-generate-table-input-number/#respond</comments>
		
		<dc:creator><![CDATA[Chitra]]></dc:creator>
		<pubDate>Fri, 14 Oct 2011 09:47:36 +0000</pubDate>
				<category><![CDATA[Simple programs]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=2253</guid>

					<description><![CDATA[<p>Here is the program which generates a table of a given input number.</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-generate-table-input-number/">Program to generate a table of a given input number</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Here is the program which generates a table of a given input number.</p>
<pre lang="c" escaped="true" line="1">
#include "conio.h"
#include "stdio.h"

void main()
{
  int num,result,i=1;
  printf("\nEnter a number to generate the table : ");
  scanf("%d",&amp;num);
  printf("\nThe table of %d is given below",num);
  while(i&lt;=10)
  {
  result=num*i;
  printf(&quot;\n\t %d * %d = %d&quot;,num,i,result);
  i++;
  }
getch();
}
</pre>
<p><strong>Output</strong></p>
<pre lang="c" escaped="true">
Enter a number to generate the table : 3
The table of 3 is given below
	3 * 1 = 3
	3 * 2 = 6
	3 * 3 = 9
	3 * 4 = 12
	3 * 5 = 15
	3 * 6 = 18
	3 * 7 = 21
	3 * 8 = 24
	3 * 9 = 27
	3 * 10 = 30
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-generate-table-input-number/">Program to generate a table of a given input number</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://studentprojects.in/software-development/c-tutorials/c/simple/program-generate-table-input-number/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Program to check a triangle is a equilateral, isosceles or scalene</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/simple/program-check-triangle-equilateral-isosceles-scalene/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/simple/program-check-triangle-equilateral-isosceles-scalene/#comments</comments>
		
		<dc:creator><![CDATA[Chitra]]></dc:creator>
		<pubDate>Thu, 13 Oct 2011 06:29:00 +0000</pubDate>
				<category><![CDATA[Simple programs]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=2249</guid>

					<description><![CDATA[<p>Here is the program to check a triangle is equilateral, isosceles or scalene.</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-check-triangle-equilateral-isosceles-scalene/">Program to check a triangle is a equilateral, isosceles or scalene</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Here is the program to check a triangle is equilateral, isosceles or scalene. </p>
<pre lang="c" escaped="true" line="1">
#include "conio.h"
#include "stdio.h"

void main()
{
  int x,y,z;
  printf("\nEnter the sides of a triangle");
  scanf("%d %d %d",&amp;x,&amp;y,&amp;z);
  if((x==y) &amp;&amp; (y==z))
  {
  printf("\nThe triangle is equilateral");
  } 
  else if((x==z) || (y==z) || (x==y))
  {
  printf("\nThe triangle is isoseles");
  }
  else
  {
  printf("\nThe triangle is scalene");
  }
getch();
}
</pre>
<p><strong>Output:</strong></p>
<pre lang="c" escaped="true">
Enter the sides of a triangle
12
10
12

The triangle is isoseles
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-check-triangle-equilateral-isosceles-scalene/">Program to check a triangle is a equilateral, isosceles or scalene</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://studentprojects.in/software-development/c-tutorials/c/simple/program-check-triangle-equilateral-isosceles-scalene/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
			</item>
		<item>
		<title>Program to accept a character and check whether entered character is vowel or not using switch statement</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/simple/program-accept-character-check-entered-charecter-vowel/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/simple/program-accept-character-check-entered-charecter-vowel/#comments</comments>
		
		<dc:creator><![CDATA[Chitra]]></dc:creator>
		<pubDate>Fri, 07 Oct 2011 13:32:04 +0000</pubDate>
				<category><![CDATA[Simple programs]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=2231</guid>

					<description><![CDATA[<p>This program accepts a character and check whether entered character is vowel or not using switch statement.</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-accept-character-check-entered-charecter-vowel/">Program to accept a character and check whether entered character is vowel or not using switch statement</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>This program accepts a character and check whether entered character is vowel or not using switch statement.</p>
<pre lang="c" escaped="true" line="1">
#include "conio.h"
#include "stdio.h"

void main()
{
  char ch;
  printf("\nEnter a charecter to check ");
  scanf("%c",&amp;ch);
  switch(ch)
  {
  case 'a':
	 printf("\nThe entered charecter %c is a vowel",ch);
	 break;
  case 'e':
	 printf("\nThe entered charecter %c is a vowel",ch);
	 break;
  case 'i':
	 printf("\nThe entered charecter %c is a vowel",ch);
	 break;
  case 'o':
	 printf("\nThe entered charecter %c is a vowel",ch);
	 break;
  case 'u':
	 printf("\nThe entered charecter %c is a vowel",ch);
	 break;
  default:
	 printf("\nThe entered is a consonant");
  }
getch();
}
</pre>
<p><strong>Output:</strong></p>
<pre lang="c" escaped="true">
Enter a charecter to check i
The entered charecter i is a vowel
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-accept-character-check-entered-charecter-vowel/">Program to accept a character and check whether entered character is vowel or not using switch statement</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://studentprojects.in/software-development/c-tutorials/c/simple/program-accept-character-check-entered-charecter-vowel/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
		<item>
		<title>Program to find out whether a entered number is divisible by 3 and 5 or not</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/simple/program-find-entered-number-divisible-3-5/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/simple/program-find-entered-number-divisible-3-5/#comments</comments>
		
		<dc:creator><![CDATA[Chitra]]></dc:creator>
		<pubDate>Fri, 07 Oct 2011 13:08:54 +0000</pubDate>
				<category><![CDATA[Simple programs]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=2229</guid>

					<description><![CDATA[<p>This program find out whether a entered number is divisible by 3 and 5 or not.</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-find-entered-number-divisible-3-5/">Program to find out whether a entered number is divisible by 3 and 5 or not</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>This program find out whether a entered number is divisible by 3 and 5 or not.</p>
<pre lang="c" escaped="true" line="1">
#include "conio.h"
#include "stdio.h"

void main()
{
  int num;
  printf("\nEnter a number ");
  scanf("%d",&amp;num);
  if(num%3==0)
  {
    if(num%5==0)
    {
      printf("\nThe number %d is divisible by 3 and 5");
    }
    else
    {
      printf("\nThe number %d is divisible by 3 but not by 5");
    }
  }
  else
  {
    printf("\nThe number %d is niether divisible by 3 nor by 5");
  }
getch();
}
</pre>
<p><strong>Output:</strong></p>
<pre lang="c" escaped="true">
Enter a number 21

Number is divisible by 3 but not by 5
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/simple/program-find-entered-number-divisible-3-5/">Program to find out whether a entered number is divisible by 3 and 5 or not</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://studentprojects.in/software-development/c-tutorials/c/simple/program-find-entered-number-divisible-3-5/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
			</item>
	</channel>
</rss>
