<?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>Number Programs | Student Projects</title>
	<atom:link href="https://studentprojects.in/category/software-development/c-tutorials/c/number/feed/" rel="self" type="application/rss+xml" />
	<link>https://studentprojects.in</link>
	<description>Microcontroller projects, Circuit Diagrams, Project Ideas</description>
	<lastBuildDate>Sat, 09 Jun 2012 16:18:27 +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>C Program to convert IP address to 32-bit longint</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/number/c-program-to-convert-ip-address-to-32-bit-longint/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/number/c-program-to-convert-ip-address-to-32-bit-longint/#respond</comments>
		
		<dc:creator><![CDATA[Ansten Lobo]]></dc:creator>
		<pubDate>Sat, 09 Jun 2012 16:18:27 +0000</pubDate>
				<category><![CDATA[Number Programs]]></category>
		<category><![CDATA[ip to int]]></category>
		<category><![CDATA[32-bit longint]]></category>
		<category><![CDATA[c program]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=3295</guid>

					<description><![CDATA[<p>Source: Dr. G T Raju, Professor &#038; Head, Dept. of CSE, RNSIT #include #include #include #include union iptolint { char ip[16]; long n; }; long conv(char []); main() { union iptolint ipl; printf(" Read the IP Address to be converted\n"); scanf("%s",ipl.ip); ipl.n=conv(ipl.ip); printf(" Equivalent 32-bit long int is : %lu \n",ipl.n); } long conv(char ipadr[])</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/c-program-to-convert-ip-address-to-32-bit-longint/">C Program to convert IP address to 32-bit longint</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Source: Dr. G T Raju, Professor &#038; Head, Dept. of CSE, RNSIT</p>
<pre lang="C" line="1">
#include <math.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
union iptolint
{
    char ip[16];
    long  n;
};

long  conv(char []);

main()
{
    union iptolint ipl;
    printf(" Read the IP Address to be converted\n");
    scanf("%s",ipl.ip);
    ipl.n=conv(ipl.ip);
    printf(" Equivalent 32-bit long int is : %lu \n",ipl.n);
}

long conv(char ipadr[])
{
    long num=0,val;
    int p=24;
    char *tok,*ptr;
    tok=strtok(ipadr,".");
    while( tok != NULL)
    {
        val=strtol(tok,&ptr,10);
        num+=  val * (long)pow(2,p);
        p=p-8;
        tok=strtok(NULL,".");
    }
    return(num);
}
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/c-program-to-convert-ip-address-to-32-bit-longint/">C Program to convert IP address to 32-bit longint</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/number/c-program-to-convert-ip-address-to-32-bit-longint/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>C Program to convert IP address to 32-bit long int</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/number/c-program-to-convert-ip-address-to-32-bit-long-int/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/number/c-program-to-convert-ip-address-to-32-bit-long-int/#comments</comments>
		
		<dc:creator><![CDATA[Ansten Lobo]]></dc:creator>
		<pubDate>Sat, 09 Jun 2012 16:03:39 +0000</pubDate>
				<category><![CDATA[Number Programs]]></category>
		<category><![CDATA[ip to 32 bit]]></category>
		<category><![CDATA[c program]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=3293</guid>

					<description><![CDATA[<p>Source: Dr. G T Raju, Professor &#038; Head, Dept. of CSE, RNSIT #include #include #include union iptolint { char ip[16]; unsigned long int n; }; unsigned long int conv(char []); main() { union iptolint ipl; printf(" Read the IP Address tobe converted\n"); scanf("%s",ipl.ip); ipl.n=conv(ipl.ip); printf(" Equivalent 32-bit long int is : %lu\n",ipl.n); } unsigned long</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/c-program-to-convert-ip-address-to-32-bit-long-int/">C Program to convert IP address to 32-bit long int</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Source: Dr. G T Raju, Professor &#038; Head, Dept. of CSE, RNSIT</p>
<pre lang="C" line="1">
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
union iptolint
{
    char ip[16];
    unsigned long int n;
};
unsigned long int conv(char []);

main()
{
    union iptolint ipl;
    printf(" Read the IP Address tobe converted\n");
    scanf("%s",ipl.ip);
    ipl.n=conv(ipl.ip);
    printf(" Equivalent 32-bit long int is : %lu\n",ipl.n);
}

unsigned long int conv(char ipadr[])
{
    unsigned long int num=0,val;
    char *tok,*ptr;
    tok=strtok(ipadr,".");
    while( tok != NULL)
    {
        val=strtoul(tok,&ptr,0);
        num=(num << 8) + val;
        tok=strtok(NULL,".");
    }
    return(num);
}
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/c-program-to-convert-ip-address-to-32-bit-long-int/">C Program to convert IP address to 32-bit long int</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/number/c-program-to-convert-ip-address-to-32-bit-long-int/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
		<item>
		<title>Program to accept a list of numbers and display it in reverse order using function concept</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/number/program-accept-list-numbers-display-reverse-order-function-concept/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/number/program-accept-list-numbers-display-reverse-order-function-concept/#comments</comments>
		
		<dc:creator><![CDATA[Chitra]]></dc:creator>
		<pubDate>Fri, 07 Oct 2011 12:34:58 +0000</pubDate>
				<category><![CDATA[Number Programs]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=2227</guid>

					<description><![CDATA[<p>This program accepts a list of numbers and displays it in reverse order using function concept. #include "stdio.h" #include "conio.h" int a[5],b[5]; void accept() { int j; printf("Enter the list \n"); for(j=0;j=0;j--,i++) { b[i]=a[j]; } } void display() { int j; printf("The list in reverse is \n"); for(j=0;j&#60;5;j++) printf(&#34;%d &#34;,b[j]); printf(&#34;\n&#34;); } void main() {</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/program-accept-list-numbers-display-reverse-order-function-concept/">Program to accept a list of numbers and display it in reverse order using function concept</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>This program accepts a list of numbers and displays it in reverse order using function concept.</p>
<pre lang="c" escaped="true" line="1">
#include "stdio.h"
#include "conio.h"

int a[5],b[5];

void accept()
{
   int j;
   printf("Enter the list \n");
   for(j=0;j=0;j--,i++)
   {
     b[i]=a[j];
   }
}

void display()
{
   int j;
   printf("The list in reverse is \n");
   for(j=0;j&lt;5;j++)
   printf(&quot;%d &quot;,b[j]);
   printf(&quot;\n&quot;);
}

void main()
{
   accept();
   reverse();
   display();
getch();
}
</pre>
<p><strong>Output:</strong></p>
<pre lang="c" escaped="true">
Enter the list
5
4
3
2
1
The list in reverse is
1 2 3 4 5
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/program-accept-list-numbers-display-reverse-order-function-concept/">Program to accept a list of numbers and display it in reverse order using function concept</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/number/program-accept-list-numbers-display-reverse-order-function-concept/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
		<item>
		<title>program to accept ten numbers from the user and display the lowest one</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/number/program-accept-ten-numbers-user-display-lowest/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/number/program-accept-ten-numbers-user-display-lowest/#comments</comments>
		
		<dc:creator><![CDATA[Chitra]]></dc:creator>
		<pubDate>Fri, 07 Oct 2011 12:05:14 +0000</pubDate>
				<category><![CDATA[Number Programs]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=2225</guid>

					<description><![CDATA[<p>This program accepts ten numbers from the user and display the lowest one, #include "conio.h" #include "stdio.h" void main() { int num[10],low,i=0,j=1; printf("\nPlease provide 10 numbers to find lowest one "); for(;i&#60;10;i++,j++) { printf(&#34;\nEnter number %d : &#34;,j); scanf(&#34;%d&#34;,&#38;num[i]); } low=num[0]; i=0,j=1; //finding greatest number for(;inum[i+1]) { low=num[i+1]; } } //displaying lowest value printf("\nThe lowest</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/program-accept-ten-numbers-user-display-lowest/">program to accept ten numbers from the user and display the lowest one</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>This program accepts ten numbers from the user and display the lowest one,</p>
<pre lang="c" escaped="true" line="1">
#include "conio.h"
#include "stdio.h"

void main()
{
  int num[10],low,i=0,j=1;
  printf("\nPlease provide 10 numbers to find lowest one ");
  for(;i&lt;10;i++,j++)
  {
  printf(&quot;\nEnter number %d : &quot;,j);
  scanf(&quot;%d&quot;,&amp;num[i]);
  }
  low=num[0];
  i=0,j=1;
//finding greatest number
  for(;inum[i+1])
    {
    low=num[i+1];
    }
  }
//displaying lowest value
  printf("\nThe lowest number is : %d",low);
getch();
}
</pre>
<p><strong>Output:</strong></p>
<pre lang="c" escaped="true">
Please provide 10 numbers to find lowest one
Enter number 1 : 45
Enter number 2 : 63
Enter number 3 : 85
Enter number 4 : 77
Enter number 5 : 21
Enter number 6 : 68
Enter number 7 : 79
Enter number 8 : 82
Enter number 9 : 101
Enter number 10 : 22
The lowest number is : 21
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/program-accept-ten-numbers-user-display-lowest/">program to accept ten numbers from the user and display the lowest one</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/number/program-accept-ten-numbers-user-display-lowest/feed/</wfw:commentRss>
			<slash:comments>3</slash:comments>
		
		
			</item>
		<item>
		<title>Program to accept ten numbers from the user and display the largest one</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/number/program-accept-ten-numbers-user-display-largest/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/number/program-accept-ten-numbers-user-display-largest/#respond</comments>
		
		<dc:creator><![CDATA[Chitra]]></dc:creator>
		<pubDate>Fri, 07 Oct 2011 11:42:47 +0000</pubDate>
				<category><![CDATA[Number Programs]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=2223</guid>

					<description><![CDATA[<p>This program accepts ten numbers from the user and displays the largest one,</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/program-accept-ten-numbers-user-display-largest/">Program to accept ten numbers from the user and display the largest one</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>This program accepts ten numbers from the user and displays the largest one,</p>
<pre lang="c" escaped="true" line="1">
#include "conio.h"
#include "stdio.h"

void main()
{
  int num[10],grt,i=0,j=1;
  printf("\nPlease provide 10 numbers to find largest one ");
  for(;i&lt;10;i++,j++)
  {
  printf(&quot;\nEnter number %d : &quot;,j);
  scanf(&quot;%d&quot;,&amp;num[i]);
  }
  grt=num[0];
  i=0,j=1;
//finding largest number
  for(;i&lt;9;i++)
  {
    if(grt&lt;num[i+1])
    {
    grt=num[i+1];
    }
  }
//displaying largest value
  printf(&quot;\nThe largest number is : %d&quot;,grt);
getch();
}
</pre>
<p><strong>Output:</strong></p>
<pre lang="c" escaped="true">
Please provide 10 numbers to find largest one
Enter number 1 : 41
Enter number 2 : 75
Enter number 3 : 76
Enter number 4 : 40
Enter number 5 : 55
Enter number 6 : 59
Enter number 7 : 48
Enter number 8 : 54
Enter number 9 : 71
Enter number 10 : 48
The largest number is : 76
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/program-accept-ten-numbers-user-display-largest/">Program to accept ten numbers from the user and display the largest one</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/number/program-accept-ten-numbers-user-display-largest/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Program to find the value of the polynomial f(x)=a4x4+a3x3+a2x2+a1x+a0 using Horner&#8217;s method</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/number/program-find-polynomial-fxa4x4a3x3a2x2a1xa0-horners-method-2/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/number/program-find-polynomial-fxa4x4a3x3a2x2a1xa0-horners-method-2/#comments</comments>
		
		<dc:creator><![CDATA[Chitra]]></dc:creator>
		<pubDate>Mon, 05 Sep 2011 16:24:55 +0000</pubDate>
				<category><![CDATA[Number Programs]]></category>
		<category><![CDATA[polynomial]]></category>
		<category><![CDATA[Horner's method]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=2119</guid>

					<description><![CDATA[<p>Here is the program to find the value of the polynomial f(x)=a4x^4+a3x^3+a2x^2+a1^x+a0 using Horner&#8217;s method #include "stdio.h" #include "conio.h" void main() { float a[100],sum=0,x; int n,i; clrscr(); printf("Enter the degree of the polynomial:"); scanf("%d",&#38;n); printf("Enter the coefficients into the array:"); for(i=n;i&#62;=0;i--) { scanf("%f",&#38;a[i]); } printf("Enter the value of x:"); scanf("%f",&#38;x); for(i=n;i&#62;0;i--) { sum=(sum+a[i])*x; } sum=sum+a[0];</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/program-find-polynomial-fxa4x4a3x3a2x2a1xa0-horners-method-2/">Program to find the value of the polynomial f(x)=a4x4+a3x3+a2x2+a1x+a0 using Horner’s method</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Here is the program to find the value of the polynomial f(x)=a4x^4+a3x^3+a2x^2+a1^x+a0 using Horner&#8217;s method</p>
<pre lang="c" escaped="true" line="1">
#include "stdio.h"
#include "conio.h"
void main()
{
 float a[100],sum=0,x;
 int n,i;
 clrscr();
 printf("Enter the degree of the polynomial:");
 scanf("%d",&amp;n);
 printf("Enter the coefficients into the array:");
 for(i=n;i&gt;=0;i--)
 {
  scanf("%f",&amp;a[i]);
 }
 printf("Enter the value of x:");
 scanf("%f",&amp;x);
 for(i=n;i&gt;0;i--)
 {
  sum=(sum+a[i])*x;
 }
 sum=sum+a[0];
 printf("\nValue of the polynomial is =%f",sum);
 getch();
}
</pre>
<p>Consider the polynomial 3x^4+2x^3+x^2+x+2 where x=2, then the output will be as follows,<br />
Output:</p>
<pre lang="c" escaped="true">
Enter the degree of the polynomial:
4
Enter the coefficients into the array:
3
2
1
1
2
Enter the value of x:
2
Value of the polynomial is:72.000000
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/program-find-polynomial-fxa4x4a3x3a2x2a1xa0-horners-method-2/">Program to find the value of the polynomial f(x)=a4x4+a3x3+a2x2+a1x+a0 using Horner’s method</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/number/program-find-polynomial-fxa4x4a3x3a2x2a1xa0-horners-method-2/feed/</wfw:commentRss>
			<slash:comments>5</slash:comments>
		
		
			</item>
		<item>
		<title>C program to calculate the GCD of a number</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/number/c-program-to-calculate-the-gcd-of-a-number/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/number/c-program-to-calculate-the-gcd-of-a-number/#respond</comments>
		
		<dc:creator><![CDATA[Editorial Team]]></dc:creator>
		<pubDate>Sun, 04 Apr 2010 13:04:32 +0000</pubDate>
				<category><![CDATA[Number Programs]]></category>
		<category><![CDATA[GCD of a number]]></category>
		<category><![CDATA[Greatest Common Divisor]]></category>
		<category><![CDATA[calculate]]></category>
		<category><![CDATA[c program]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=1136</guid>

					<description><![CDATA[<p>Write a program to calculate the Greatest Common Divisor(GCD) of a number #include #include #include int gcd(int m,int n) { int rem; while(n!=0) { rem=m%n; m=n; n=rem; } return(m); } main() { int num1,num2,num3,gcd1,gcd2; clrscr(); printf("Enter three positive integers"); scanf("%d%d%d",&#038;num1,&#038;num2,&#038;num3); if(num1==0 &#038;& num2==0 &#038;& num3==0) { printf("\n Invalid number"); exit(0); } gcd1=gcd(num1,num2); gcd2=gcd(num3,gcd1); printf("\n GCD</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/c-program-to-calculate-the-gcd-of-a-number/">C program to calculate the GCD of a number</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Write a program to calculate the Greatest Common Divisor(GCD) of a number</p>
<pre lang="c">
#include<stdio.h>
#include<conio.h>
#include<process.h>
int gcd(int m,int n)
{
	int rem;
	while(n!=0)
	{
		rem=m%n;
		m=n;
		n=rem;
	}
	return(m);
}
main()
{
	int num1,num2,num3,gcd1,gcd2;
	clrscr();
	printf("Enter three positive integers");
	scanf("%d%d%d",&num1,&num2,&num3);
	if(num1==0 && num2==0 && num3==0)
	{
		printf("\n Invalid number");
		exit(0);
	}
	gcd1=gcd(num1,num2);
	gcd2=gcd(num3,gcd1);
	printf("\n GCD of %d %d %d is : %d\n",num1,num2,num3,gcd2);
	getch();
}
</pre><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/c-program-to-calculate-the-gcd-of-a-number/">C program to calculate the GCD of a 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/number/c-program-to-calculate-the-gcd-of-a-number/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>C program for finding remainder</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/number/c-program-for-finding-remainder/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/number/c-program-for-finding-remainder/#respond</comments>
		
		<dc:creator><![CDATA[Editorial Team]]></dc:creator>
		<pubDate>Sun, 20 Sep 2009 04:35:20 +0000</pubDate>
				<category><![CDATA[Number Programs]]></category>
		<category><![CDATA[binary remainder]]></category>
		<category><![CDATA[finding remainder]]></category>
		<category><![CDATA[c programs]]></category>
		<category><![CDATA[source code]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=783</guid>

					<description><![CDATA[<p>OUTPUT:<br />
enter frame:<br />
1 0 1 1 0 1 0 0<br />
enter generator:<br />
1 0 1 0<br />
remainder is:<br />
0 0 1 0</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/c-program-for-finding-remainder/">C program for finding remainder</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>OUTPUT:<br />
enter frame:<br />
1 0 1 1 0 1 0 0<br />
enter generator:<br />
1 0 1 0<br />
remainder is:<br />
0 0 1 0</p>
<pre lang="c" escaped="true" line="1">
#include<stdio.h>
#include<conio.h>
void main()
{
 int  i,j,gen[4],rem[4],frl=8,genl=4,k,k1,fr[11];
 clrscr();
 printf("enter frame:");
 for(i=0;i<frl;i++)
{ 
scanf("%d",&#038;fr[i]);
} 
for(i=frl;i<11;i++)
{ 
fr[i]=0;
}
printf("enter generator:");
 for(i=0;i<4;i++)
 scanf("%d",&#038;gen[i]);
  for(k=0;k<frl;k++)
  {
   if(fr[k]==1)
   {
   k1=k;
    for(i=0,j=k;i<genl;i++,j++)
    {
     rem[i]=fr[j]^gen[i];
    }

    for(i=0;i<genl;i++)
    {
	  fr[k1]=rem[i];
     k1++;
    }
   }
    }
      printf("\nremainder is: ");
      for(i=0;i<4;i++)
     printf("%d",rem[i]);
     getch();
}
</pre>
<p>OUTPUT:<br />
enter frame:<br />
1 0 1 1 0 1 0 0<br />
enter generator:<br />
1 0 1 0<br />
remainder is:<br />
0 0 1 0</p><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/c-program-for-finding-remainder/">C program for finding remainder</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/number/c-program-for-finding-remainder/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>To find the sum of the cos series</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/number/to-find-the-sum-of-the-cos-series/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/number/to-find-the-sum-of-the-cos-series/#respond</comments>
		
		<dc:creator><![CDATA[Editorial Team]]></dc:creator>
		<pubDate>Thu, 04 Dec 2008 06:04:45 +0000</pubDate>
				<category><![CDATA[Number Programs]]></category>
		<category><![CDATA[Source Codes]]></category>
		<category><![CDATA[C/C++ Programms]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=345</guid>

					<description><![CDATA[<p>Here is the program to find the Cosine of the given angle for the user defined accuracy. This is a fast, reliable and robust program, which uses no sophisticated functions but a simple while loop and other math functions. Logic: The program follows the mathematical cosine series, where cosine of the entered radian angle ?</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/to-find-the-sum-of-the-cos-series/">To find the sum of the cos series</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Here is the program to find the Cosine of the given angle for the user defined accuracy. This is a fast, reliable and robust program, which uses no sophisticated functions but a simple while loop and other math functions.</p>
<p>Logic: The program follows the mathematical cosine series, where cosine of the entered radian angle ? is,</p>
<p>The program asks the user to enter the Angle x° . Also it asks for the number of iterations &#8216;n&#8217; that the cosine loop should iterate. As the iteration increases, the accuracy boosts up. After the desired loop, the resultant gets printed out. Similar algorithm can be set to find the Sine value of the given number.</p>
<p>#include&lt;stdio.h&gt;<br />
#include&lt;math.h&gt;<br />
void main()<br />
{<br />
float pow = 2.0, nr, dr = 1.0, x1, sum;<br />
int i = 1,n,s = -1,x;<br />
clrscr();<br />
printf(&#8220;\n\n\t ENTER THE ANGLE&#8230;: &#8220;);<br />
scanf(&#8220;%d&#8221;, &amp;x);<br />
x1 = 3.142 * (x / 180.0);<br />
sum = 1.0;<br />
nr = x1*x1;<br />
printf(&#8220;\n\t ENTER THE NUMBER OF TERMS&#8230;: &#8220;);<br />
scanf(&#8220;%d&#8221;,&amp;n);<br />
while(i&lt;=n)<br />
{<br />
dr = dr * pow * (pow &#8211; 1.0);<br />
sum = sum + (nr / (dr * s));<br />
s = s * (-1);<br />
pow = pow + 2.0;<br />
nr = nr * x1 * x1;<br />
i++;<br />
}<br />
printf(&#8220;\n\t THE SUM OF THE COS SERIES IS..: %0.3f&#8221;, sum);<br />
getch();<br />
}<br />
<a href="https://studentprojects.in/wp-content/uploads/2008/12/cos.zip">Download exe and source code here.</a></p><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/to-find-the-sum-of-the-cos-series/">To find the sum of the cos series</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/number/to-find-the-sum-of-the-cos-series/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Program to find the sum of the sine series</title>
		<link>https://studentprojects.in/software-development/c-tutorials/c/number/program-to-find-the-sum-of-the-sine-series/</link>
					<comments>https://studentprojects.in/software-development/c-tutorials/c/number/program-to-find-the-sum-of-the-sine-series/#comments</comments>
		
		<dc:creator><![CDATA[Editorial Team]]></dc:creator>
		<pubDate>Thu, 04 Dec 2008 06:01:44 +0000</pubDate>
				<category><![CDATA[Number Programs]]></category>
		<category><![CDATA[Source Codes]]></category>
		<category><![CDATA[C/C++ Programms]]></category>
		<guid isPermaLink="false">http://studentprojects.in/?p=342</guid>

					<description><![CDATA[<p>Here is the program to find the Sinusoidal value of the given angle for the user defined accuracy. This is a fast, reliable and robust program, which uses no built in functions but a simple while loop and other math functions. Logic: The program follows the mathematical sine series, where cosine of the entered radian</p>
<p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/program-to-find-the-sum-of-the-sine-series/">Program to find the sum of the sine series</a> first appeared on <a href="https://studentprojects.in">Student Projects</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Here is the program to find the Sinusoidal value of the given angle for the user defined accuracy. This is a fast, reliable and robust program, which uses no built in functions but a simple while loop and other math functions.</p>
<p>Logic: The program follows the mathematical sine series, where cosine of the entered radian angle x  is,</p>
<p>The program asks the user to enter the Angle x° . Also it asks for the number of iterations &#8216;n&#8217; that the sine loop should iterate. As the iteration increases, the accuracy boosts up. After the desired loop, the resultant gets printed out. Similar algorithm can be set to find the Cosine value of the given number.</p>
<p>#include&lt;stdio.h&gt;<br />
#include&lt;math.h&gt;<br />
void main()<br />
{<br />
int i = 2, n, s = 1, x, pwr = 1, dr;<br />
float nr = 1, x1, sum;<br />
clrscr();<br />
printf(&#8220;\n\n\t ENTER THE ANGLE&#8230;: &#8220;);<br />
scanf(&#8220;%d&#8221;, &amp;x);<br />
x1 = 3.142 * (x / 180.0);<br />
sum = x1;<br />
printf(&#8220;\n\t ENTER THE NUMBER OF TERMS&#8230;: &#8220;);<br />
scanf(&#8220;%d&#8221;, &amp;n);<br />
while(i &lt;= n)<br />
{<br />
pwr = pwr + 2;<br />
dr = dr * pwr * (pwr &#8211; 1);<br />
sum = sum + (nr / dr) * s;<br />
s = s * (-1);<br />
nr = nr * x1 * x1;<br />
i+= 2;<br />
}<br />
printf(&#8220;\n\t THE SUM OF THE SINE SERIES IS..: %0.3f&#8221;,sum);<br />
getch();<br />
}<br />
<a href="https://studentprojects.in/wp-content/uploads/2008/12/sine.zip">Download exe and source code here.</a></p><p>The post <a href="https://studentprojects.in/software-development/c-tutorials/c/number/program-to-find-the-sum-of-the-sine-series/">Program to find the sum of the sine series</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/number/program-to-find-the-sum-of-the-sine-series/feed/</wfw:commentRss>
			<slash:comments>6</slash:comments>
		
		
			</item>
	</channel>
</rss>
