<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-7629947319940983854</id><updated>2024-09-01T16:28:58.850-07:00</updated><category term="character arrays in c"/><category term="string reverse program in C++"/><category term="C functions"/><category term="C program to print difference of two matrices"/><category term="C program to print numbers pattern"/><category term="C program to print pyramid"/><category term="C++ program to calculate the length of the string"/><category term="C++ program to check a palindrome string"/><category term="C++ program to convert binary to decimal"/><category term="C++ program to convert decimal to binary"/><category term="C++ program to convert numbers to words"/><category term="C++ program to find lcm and hcf"/><category term="C++ program to print armstrong numbers between 1 to 1000"/><category term="C++ program to print pattern of numbers with each line reversing the previous line"/><category term="C++ program to print pyramid of asterisks"/><category term="C++ program to print pythagoran triplets between 1 to 1000"/><category term="C++ program to print reverse of a string"/><category term="C++ program to print sum of two matrices"/><category term="C++ to print initials"/><category term="IT quiz"/><category term="Prefix and postfix in c programming"/><category term="Quick sort program in C++"/><category term="What is call by value and call by reference in c++"/><category term="What is difference between call by value and call by reference in c++"/><category term="accept name print initials"/><category term="armstrong numbers program in C++"/><category term="array basics in C programming language"/><category term="arrays in C++"/><category term="arrays tutorials in C"/><category term="binary to decimal conversion"/><category term="c program to accept a name and print initials"/><category term="c program to add two matrix"/><category term="c program to print star pyramid"/><category term="c program to print transpose of a matrix"/><category term="c program to quick sort numbers"/><category term="c program to tell if a string is palindrome or not"/><category term="call by value and call by reference c++"/><category term="character count program in c"/><category term="cloud computing"/><category term="cloud computing companies"/><category term="cloud computing providers"/><category term="cloud computing wiki"/><category term="computer quiz"/><category term="computer quiz questions and answers"/><category term="convert a name to initials"/><category term="data structures in c"/><category term="decimal to binary conversion"/><category term="difference of two matrices program in C++"/><category term="digits to words"/><category term="dynamic memory allocation"/><category term="evaluation order of prefix and postfix in c programming"/><category term="function arguments"/><category term="function prototype"/><category term="functions in c"/><category term="how cloud computing works"/><category term="how pointers work in c"/><category term="how prefix and postfix work in c"/><category term="how to calculate length of a string without using strlen function in C"/><category term="how to convert binary to decimal"/><category term="how to convert decimal to binary"/><category term="how to print transpose of a matrix in C programming"/><category term="how to reverse a string in C++"/><category term="how to subtract one matrix from other in C++"/><category term="how to use arrays in c programming"/><category term="how to use functions in C"/><category term="information technology"/><category term="information technology quiz"/><category term="lcm and hcf program in C++"/><category term="matrix sum program in c programming"/><category term="numbers to words program"/><category term="palindrome string program in c"/><category term="pointer and array"/><category term="pointer arithmetic"/><category term="pointer memory allocation"/><category term="pointers in c programming"/><category term="pointers in c++"/><category term="print initials"/><category term="pytha goran triplets program in C++"/><category term="return value in functions"/><category term="string length program in C++"/><category term="string palindrome program in C"/><category term="transpose matrix program in C++"/><category term="use of functions in C++"/><category term="what is cloud computing"/><title type='text'>Programming@3asss</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default?start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>26</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-5626574283327200596</id><published>2011-10-20T04:40:00.000-07:00</published><updated>2022-06-15T01:12:46.452-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C program to print difference of two matrices"/><category scheme="http://www.blogger.com/atom/ns#" term="difference of two matrices program in C++"/><category scheme="http://www.blogger.com/atom/ns#" term="how to subtract one matrix from other in C++"/><title type='text'>C++ program to print matrix difference</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;br /&gt;
//C++ program to subtract two matrices&lt;br /&gt;
#include&amp;lt;iostream.h&amp;gt;&lt;br /&gt;
#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;
void main()&lt;br /&gt;
{&lt;br /&gt;
clrscr();&lt;br /&gt;
int matrix1[3][4],matrix2[3][4],matrix3[3][4];&lt;br /&gt;
int i,j;&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\nEnter numbers to fill matrix 1\n&quot;;&lt;br /&gt;
for(i=0;i&amp;lt;3;i++)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; for(j=0;j&amp;lt;4;j++)&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp;cin&amp;gt;&amp;gt;matrix1[i][j];&lt;br /&gt;
&amp;nbsp; }&lt;br /&gt;
}&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\nEnter numbers to fill matrix 2\n&quot;;&lt;br /&gt;
for(i=0;i&amp;lt;3;i++)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; for(j=0;j&amp;lt;4;j++)&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp;cin&amp;gt;&amp;gt;matrix2[i][j];&lt;br /&gt;
&amp;nbsp; }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;Original Matrix 1:\n&quot;;&lt;br /&gt;
for(i=0;i&amp;lt;3;i++)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; for(j=0;j&amp;lt;4;j++)&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp;cout&amp;lt;&amp;lt;matrix1[i][j]&amp;lt;&amp;lt;&quot; &quot;;&lt;br /&gt;
&amp;nbsp; }&lt;br /&gt;
&amp;nbsp;cout&amp;lt;&amp;lt;&quot;\n&quot;;&lt;br /&gt;
}&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\n\nOriginal Matrix 2:\n&quot;;&lt;br /&gt;
&lt;br /&gt;
for(i=0;i&amp;lt;3;i++)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; for(j=0;j&amp;lt;4;j++)&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp;cout&amp;lt;&amp;lt;matrix2[i][j]&amp;lt;&amp;lt;&quot; &quot;;&lt;br /&gt;
&amp;nbsp; }&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\n&quot;;&lt;br /&gt;
}&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\n\nDifference of Matrix 1 and Matrix 2:\n&quot;;&lt;br /&gt;
&lt;br /&gt;
for(i=0;i&amp;lt;3;i++)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; for(j=0;j&amp;lt;4;j++)&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp;matrix3[i][j]=matrix1[i][j]-matrix2[i][j];&lt;br /&gt;
&amp;nbsp; &amp;nbsp;cout&amp;lt;&amp;lt;matrix3[i][j]&amp;lt;&amp;lt;&quot; &quot;;&lt;br /&gt;
&amp;nbsp; }&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\n&quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
getch();&lt;br /&gt;
}&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/5626574283327200596/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-print-matrix-difference.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/5626574283327200596'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/5626574283327200596'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-print-matrix-difference.html' title='C++ program to print matrix difference'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-905605221431528156</id><published>2011-10-20T04:38:00.000-07:00</published><updated>2022-06-15T01:12:46.360-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="c program to add two matrix"/><category scheme="http://www.blogger.com/atom/ns#" term="C++ program to print sum of two matrices"/><category scheme="http://www.blogger.com/atom/ns#" term="matrix sum program in c programming"/><title type='text'>C++ program to print sum of two matrices</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;br /&gt;
//C++ program to sum two matrices&lt;br /&gt;
#include&amp;lt;iostream.h&amp;gt;&lt;br /&gt;
#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;
void main()&lt;br /&gt;
{&lt;br /&gt;
clrscr();&lt;br /&gt;
int matrix1[3][4],matrix2[3][4],matrix3[3][4];&lt;br /&gt;
int i,j;&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\nEnter numbers to fill matrix 1\n&quot;;&lt;br /&gt;
for(i=0;i&amp;lt;3;i++)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; for(j=0;j&amp;lt;4;j++)&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp;cin&amp;gt;&amp;gt;matrix1[i][j];&lt;br /&gt;
&amp;nbsp; }&lt;br /&gt;
}&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\nEnter numbers to fill matrix 2\n&quot;;&lt;br /&gt;
for(i=0;i&amp;lt;3;i++)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; for(j=0;j&amp;lt;4;j++)&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp;cin&amp;gt;&amp;gt;matrix2[i][j];&lt;br /&gt;
&amp;nbsp; }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;Original Matrix 1:\n&quot;;&lt;br /&gt;
for(i=0;i&amp;lt;3;i++)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; for(j=0;j&amp;lt;4;j++)&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp;cout&amp;lt;&amp;lt;matrix1[i][j]&amp;lt;&amp;lt;&quot; &quot;;&lt;br /&gt;
&amp;nbsp; }&lt;br /&gt;
&amp;nbsp;cout&amp;lt;&amp;lt;&quot;\n&quot;;&lt;br /&gt;
}&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\n\nOriginal Matrix 2:\n&quot;;&lt;br /&gt;
&lt;br /&gt;
for(i=0;i&amp;lt;3;i++)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; for(j=0;j&amp;lt;4;j++)&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp;cout&amp;lt;&amp;lt;matrix2[i][j]&amp;lt;&amp;lt;&quot; &quot;;&lt;br /&gt;
&amp;nbsp; }&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\n&quot;;&lt;br /&gt;
}&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\n\nSum of Matrix 1 and Matrix 2:\n&quot;;&lt;br /&gt;
&lt;br /&gt;
for(i=0;i&amp;lt;3;i++)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; for(j=0;j&amp;lt;4;j++)&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp;matrix3[i][j]=matrix1[i][j]+matrix2[i][j];&lt;br /&gt;
&amp;nbsp; &amp;nbsp;cout&amp;lt;&amp;lt;matrix3[i][j]&amp;lt;&amp;lt;&quot; &quot;;&lt;br /&gt;
&amp;nbsp; }&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\n&quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
getch();&lt;br /&gt;
}&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/905605221431528156/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-print-sum-of-two-matrices.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/905605221431528156'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/905605221431528156'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-print-sum-of-two-matrices.html' title='C++ program to print sum of two matrices'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-5188606234924010132</id><published>2011-10-20T04:36:00.000-07:00</published><updated>2022-06-15T01:12:46.446-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="c program to print transpose of a matrix"/><category scheme="http://www.blogger.com/atom/ns#" term="how to print transpose of a matrix in C programming"/><category scheme="http://www.blogger.com/atom/ns#" term="transpose matrix program in C++"/><title type='text'>C program to print transpose matrix</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;br /&gt;
//C++ program to print transpose of a matrix&lt;br /&gt;
#include&amp;lt;iostream.h&amp;gt;&lt;br /&gt;
#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;
void main()&lt;br /&gt;
{&lt;br /&gt;
clrscr();&lt;br /&gt;
int matrix[3][4],transpose_matrix[4][3];&lt;br /&gt;
int i,j;&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\nEnter numbers to fill matrix\n&quot;;&lt;br /&gt;
for(i=0;i&amp;lt;3;i++)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; for(j=0;j&amp;lt;4;j++)&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp;cin&amp;gt;&amp;gt;matrix[i][j];&lt;br /&gt;
&amp;nbsp; &amp;nbsp;transpose_matrix[j][i]=matrix[i][j];&lt;br /&gt;
&amp;nbsp; }&lt;br /&gt;
}&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;Original Matrix:\n&quot;;&lt;br /&gt;
for(i=0;i&amp;lt;3;i++)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; for(j=0;j&amp;lt;4;j++)&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp;cout&amp;lt;&amp;lt;matrix[i][j]&amp;lt;&amp;lt;&quot; &quot;;&lt;br /&gt;
&amp;nbsp; }&lt;br /&gt;
&amp;nbsp;cout&amp;lt;&amp;lt;&quot;\n&quot;;&lt;br /&gt;
}&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\n\nTranspose of Matrix:\n&quot;;&lt;br /&gt;
&lt;br /&gt;
for(i=0;i&amp;lt;4;i++)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp; for(j=0;j&amp;lt;3;j++)&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp; &amp;nbsp;cout&amp;lt;&amp;lt;transpose_matrix[i][j]&amp;lt;&amp;lt;&quot; &quot;;&lt;br /&gt;
&amp;nbsp; }&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;\n&quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
getch();&lt;br /&gt;
}&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/5188606234924010132/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-print-transpose-matrix.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/5188606234924010132'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/5188606234924010132'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-print-transpose-matrix.html' title='C program to print transpose matrix'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-364363795315515245</id><published>2011-10-18T00:26:00.000-07:00</published><updated>2022-06-15T01:12:46.325-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="evaluation order of prefix and postfix in c programming"/><category scheme="http://www.blogger.com/atom/ns#" term="how prefix and postfix work in c"/><category scheme="http://www.blogger.com/atom/ns#" term="Prefix and postfix in c programming"/><title type='text'>Tutorial on Prefix and Postfix in C programming</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;The prefix and postfix notations in C++ are really simple
for an expert but extremely difficult for novice to understand. In this
tutorial, you can easily understand the working of increment and decrement
operators in prefix and postfix notation.&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;Consider the following codes &lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;Code 1&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void main()&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;clrscr();&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int b,i=10;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;b=i++ + ++i;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;b;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;getch();&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;OUTPUT will be 22. &lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;Code 2&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void main()&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;clrscr();&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int i=10;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;i=i++ + ++i;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;i;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;getch();&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;} &lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;OUTPUT will be 23.&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;Wonder how? Do not wonder. I will explain how it works. &lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;Explanation: Prefix notation is always given first priority
over postfix notation to execute. Just see the priority setting for each
operation and understand how it works:&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;b&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;Code 1&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;b&lt;b&gt;=&lt;/b&gt;&lt;sup&gt;3&lt;/sup&gt;(i++)&lt;sup&gt;4&lt;/sup&gt;
&lt;b&gt;+&lt;/b&gt;&lt;sup&gt;2&lt;/sup&gt; (++i)&lt;sup&gt;1&lt;/sup&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;See the priority orders as 1, 2, 3 and 4. First prefix i
increases and becomes 11. Secondly, + operator adds 11+11 and thirdly =
operator assigns 22 to b and lastly postfix i increases to 12. So finally b=22
and i=12.&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;Code 2&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;i&lt;b&gt;=&lt;/b&gt;&lt;sup&gt;3&lt;/sup&gt;(i++)&lt;sup&gt;4&lt;/sup&gt;
&lt;b&gt;+&lt;/b&gt;&lt;sup&gt;2&lt;/sup&gt; (++i)&lt;sup&gt;1&lt;/sup&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;See the priority orders as 1, 2, 3 and 4. First prefix i
increases and becomes 11. Secondly, + operator adds 11+11 and thirdly =
operator assigns 22 to i and lastly postfix i increases to 23. So finally i=23.&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;I hope you understood the working of prefix and postfix in
the above examples. Share it if you liked this tutorial.&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/364363795315515245/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/tutorial-on-prefix-and-postfix-in-c.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/364363795315515245'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/364363795315515245'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/tutorial-on-prefix-and-postfix-in-c.html' title='Tutorial on Prefix and Postfix in C programming'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-1228991141781357303</id><published>2011-10-17T20:15:00.000-07:00</published><updated>2022-06-15T01:12:46.376-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="c program to tell if a string is palindrome or not"/><category scheme="http://www.blogger.com/atom/ns#" term="C++ program to check a palindrome string"/><category scheme="http://www.blogger.com/atom/ns#" term="string palindrome program in C"/><title type='text'>C++ program to check a palindrome string</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;//C++ program to check a palindrome string&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;stdio.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void main()&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;clrscr();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int i,j,flag=0;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;char string[20];&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;Enter A String\n&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cin&amp;gt;&amp;gt;string;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;for(i=0;string[i]!=&#39;\0&#39;;i++);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;for(j=0,--i;i&amp;gt;=0;--i,++j)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;if(string[i]!=string[j])&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;flag=1;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;if(flag)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;Not a palindrome string&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;else&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;Palindrome String&quot;;&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;getch();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;OUTPUT:&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgHc4s9P3JifdBrjKzvbLfeMsg-FQxSWCtwE6_CYK-5fhXJamlSX0oAq0eW3AEuyEvo6fCr8HxYYqHZaNHnG1ocquZSsEY3OEVPPDoXBrW8EMtVqT8kmNZqN5fgNsri7uiviBt0dZ_r1hA/s1600/NOT+PALIN.JPG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;132&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgHc4s9P3JifdBrjKzvbLfeMsg-FQxSWCtwE6_CYK-5fhXJamlSX0oAq0eW3AEuyEvo6fCr8HxYYqHZaNHnG1ocquZSsEY3OEVPPDoXBrW8EMtVqT8kmNZqN5fgNsri7uiviBt0dZ_r1hA/s400/NOT+PALIN.JPG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh3XLIqM9AIJwgvnaa-4otwV4rypfMEtVH5PSQPnFEVitfPtBPrXq_KOt1nxz5bpr8cc19yUoaiCFohryq4g3ZyvpwoHDfDwePnNTXKNV2Yd5jnd6rYGrwAdLBvK7bx2WgH5rDPGeAYWwQ/s1600/PALINDROME.JPG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;113&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh3XLIqM9AIJwgvnaa-4otwV4rypfMEtVH5PSQPnFEVitfPtBPrXq_KOt1nxz5bpr8cc19yUoaiCFohryq4g3ZyvpwoHDfDwePnNTXKNV2Yd5jnd6rYGrwAdLBvK7bx2WgH5rDPGeAYWwQ/s400/PALINDROME.JPG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/1228991141781357303/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-check-palindrome-string.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/1228991141781357303'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/1228991141781357303'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-check-palindrome-string.html' title='C++ program to check a palindrome string'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgHc4s9P3JifdBrjKzvbLfeMsg-FQxSWCtwE6_CYK-5fhXJamlSX0oAq0eW3AEuyEvo6fCr8HxYYqHZaNHnG1ocquZSsEY3OEVPPDoXBrW8EMtVqT8kmNZqN5fgNsri7uiviBt0dZ_r1hA/s72-c/NOT+PALIN.JPG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-2419774587406807154</id><published>2011-10-17T00:20:00.000-07:00</published><updated>2022-06-15T01:12:46.403-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C++ program to calculate the length of the string"/><category scheme="http://www.blogger.com/atom/ns#" term="how to calculate length of a string without using strlen function in C"/><category scheme="http://www.blogger.com/atom/ns#" term="string length program in C++"/><title type='text'>C++ program to calculate length of a string</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;br /&gt;
//C++ program to calculate the length of the string&lt;br /&gt;
#include&amp;lt;iostream.h&amp;gt;&lt;br /&gt;
#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;
#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;
void main()&lt;br /&gt;
{&lt;br /&gt;
clrscr();&lt;br /&gt;
int i;&lt;br /&gt;
char string[20];&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;Enter A String\n&quot;;&lt;br /&gt;
gets(string);&lt;br /&gt;
for(i=0;string[i]!=&#39;\0&#39;;i++);&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;The length of the string is&quot;&amp;lt;&amp;lt;i;&lt;br /&gt;
getch();&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
Output:&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgTe2ypIX7BKnj0kWyHQANzsqa7jVNRkBFlI9YkYAbs_7mfTvGGBJbI9i34bCAYKYfPPdyOtwt7X_KR_9f_iY02v7bW7r3pDWkQ8EdHFJbFdHdBjp2pwQMmFuOTVFXoimF6PAFMUG0HpTE/s1600/string+length+output.JPG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;170&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgTe2ypIX7BKnj0kWyHQANzsqa7jVNRkBFlI9YkYAbs_7mfTvGGBJbI9i34bCAYKYfPPdyOtwt7X_KR_9f_iY02v7bW7r3pDWkQ8EdHFJbFdHdBjp2pwQMmFuOTVFXoimF6PAFMUG0HpTE/s400/string+length+output.JPG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;/div&gt;
&lt;br /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/2419774587406807154/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-calculate-length-of-string.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/2419774587406807154'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/2419774587406807154'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-calculate-length-of-string.html' title='C++ program to calculate length of a string'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgTe2ypIX7BKnj0kWyHQANzsqa7jVNRkBFlI9YkYAbs_7mfTvGGBJbI9i34bCAYKYfPPdyOtwt7X_KR_9f_iY02v7bW7r3pDWkQ8EdHFJbFdHdBjp2pwQMmFuOTVFXoimF6PAFMUG0HpTE/s72-c/string+length+output.JPG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-3823433759497184090</id><published>2011-10-17T00:08:00.000-07:00</published><updated>2022-06-15T01:12:46.423-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C++ program to print reverse of a string"/><category scheme="http://www.blogger.com/atom/ns#" term="how to reverse a string in C++"/><category scheme="http://www.blogger.com/atom/ns#" term="string reverse program in C++"/><title type='text'>C++ program to print reverse of a string</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;//C++ program to print reverse of a string&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;stdio.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void main()&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;clrscr();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int i;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;char string[20];&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;Enter A String\n&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;gets(string);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;for(i=0;string[i]!=&#39;\0&#39;;i++);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;for(i=i-1;i&amp;gt;=0;i--)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;string[i];&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;getch();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;Output:&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj8L2kdzQMxv-UsUjvq7-sLcgOtpy7ZGA4PmDLovGGGScU_SFf7BO-1CA0Td6UWajty18u-RXlwbTa0FH3GvhHyx_Z95zRdtsb9rxVRg6cWyrOBEutqPH7FxfeAIEyadbXDV38Ivw-Qscc/s1600/string_reverse_output.JPG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;115&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj8L2kdzQMxv-UsUjvq7-sLcgOtpy7ZGA4PmDLovGGGScU_SFf7BO-1CA0Td6UWajty18u-RXlwbTa0FH3GvhHyx_Z95zRdtsb9rxVRg6cWyrOBEutqPH7FxfeAIEyadbXDV38Ivw-Qscc/s400/string_reverse_output.JPG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/3823433759497184090/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-print-reverse-of-string.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/3823433759497184090'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/3823433759497184090'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-print-reverse-of-string.html' title='C++ program to print reverse of a string'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj8L2kdzQMxv-UsUjvq7-sLcgOtpy7ZGA4PmDLovGGGScU_SFf7BO-1CA0Td6UWajty18u-RXlwbTa0FH3GvhHyx_Z95zRdtsb9rxVRg6cWyrOBEutqPH7FxfeAIEyadbXDV38Ivw-Qscc/s72-c/string_reverse_output.JPG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-1575364789992311444</id><published>2011-10-16T23:12:00.000-07:00</published><updated>2022-06-15T01:12:46.390-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C program to print pyramid"/><category scheme="http://www.blogger.com/atom/ns#" term="c program to print star pyramid"/><category scheme="http://www.blogger.com/atom/ns#" term="C++ program to print pyramid of asterisks"/><title type='text'>C program to print pyramid of asterisks</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;//C++ program to print pyramid of asterisks&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void main()&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;clrscr();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int i,j,k,l,sp1=4,sp2=-1;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;for(i=1;i&amp;lt;=5;i++,sp1--,sp2=sp2+2)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;for(j=1;j&amp;lt;=sp1;j++)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;cout&amp;lt;&amp;lt;&quot; &quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;if(i==1)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; cout&amp;lt;&amp;lt;&quot;*&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;if(i==2||i==3||i==4)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; cout&amp;lt;&amp;lt;&quot;*&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; for(k=1;k&amp;lt;=sp2;k++)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; {&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; cout&amp;lt;&amp;lt;&quot; &quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; }&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; cout&amp;lt;&amp;lt;&quot;*&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;if(i==5)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;for(l=1;l&amp;lt;=9;l++)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;cout&amp;lt;&amp;lt;&quot;*&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp;cout&amp;lt;&amp;lt;&quot;\n&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;getch();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;The output:&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEibAoulfManNrSZHq32wWPwqENxB5fuvjOnyYbe4ZIlh0wx1iPlLf_gycbzRcZ8mkLNvuOwW1AVzfwCkfCD6JealDj4JKuLTe57pD-gUWPJmBbmXFHIKxHk3Os93WrYcJU4DJReL-d3Q08/s1600/star_pyramid+output.bmp&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;210&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEibAoulfManNrSZHq32wWPwqENxB5fuvjOnyYbe4ZIlh0wx1iPlLf_gycbzRcZ8mkLNvuOwW1AVzfwCkfCD6JealDj4JKuLTe57pD-gUWPJmBbmXFHIKxHk3Os93WrYcJU4DJReL-d3Q08/s400/star_pyramid+output.bmp&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/1575364789992311444/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-print-pyramid-of-asterisks.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/1575364789992311444'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/1575364789992311444'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-print-pyramid-of-asterisks.html' title='C program to print pyramid of asterisks'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEibAoulfManNrSZHq32wWPwqENxB5fuvjOnyYbe4ZIlh0wx1iPlLf_gycbzRcZ8mkLNvuOwW1AVzfwCkfCD6JealDj4JKuLTe57pD-gUWPJmBbmXFHIKxHk3Os93WrYcJU4DJReL-d3Q08/s72-c/star_pyramid+output.bmp" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-266951283628453021</id><published>2011-10-16T23:02:00.000-07:00</published><updated>2022-06-15T01:12:46.306-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C program to print numbers pattern"/><category scheme="http://www.blogger.com/atom/ns#" term="C++ program to print pattern of numbers with each line reversing the previous line"/><title type='text'>C++ program to print pattern of numbers with each line reversing the previous line</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;//C++ program to print pattern of numbers with each line reversing the previous line&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void main()&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;int i,k,t,a=1,s=0;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;clrscr();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;for(i=6;i&amp;gt;=1; i--)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp; if(i%2==0)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp; &amp;nbsp; for(k=1;k&amp;lt;=i;k++)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt; cout&amp;lt;&amp;lt;a&amp;lt;&amp;lt;&quot; &amp;nbsp; &quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt; ++a;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;  &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp; &amp;nbsp;cout&amp;lt;&amp;lt;&quot;\n&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp; &amp;nbsp;t=a;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp; &amp;nbsp;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp;if(i%2!=0)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp; for(s=t+i-1;s&amp;gt;=t;s--,a++)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp; cout&amp;lt;&amp;lt;s&amp;lt;&amp;lt;&quot; &amp;nbsp; &quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp;cout&amp;lt;&amp;lt;&quot;\n&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt; &amp;nbsp;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt; &lt;/span&gt;getch();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;The output will be as following:&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg0I03zJWgWjT7u4hAuDvIE_xgrwGR3d-8izwo-lgPlGaH8Qcwx8FfoiezLwt2nU8JMxaf4CjD2g0b8R0tpDvyHw1fohqGTTJH4Hbrj93ur_nxRP3q33IOaG8bE7t7sZBItxCrWENpGM18/s1600/output.JPG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;130&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg0I03zJWgWjT7u4hAuDvIE_xgrwGR3d-8izwo-lgPlGaH8Qcwx8FfoiezLwt2nU8JMxaf4CjD2g0b8R0tpDvyHw1fohqGTTJH4Hbrj93ur_nxRP3q33IOaG8bE7t7sZBItxCrWENpGM18/s400/output.JPG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/266951283628453021/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-print-pattern-of-numbers.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/266951283628453021'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/266951283628453021'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/10/c-program-to-print-pattern-of-numbers.html' title='C++ program to print pattern of numbers with each line reversing the previous line'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg0I03zJWgWjT7u4hAuDvIE_xgrwGR3d-8izwo-lgPlGaH8Qcwx8FfoiezLwt2nU8JMxaf4CjD2g0b8R0tpDvyHw1fohqGTTJH4Hbrj93ur_nxRP3q33IOaG8bE7t7sZBItxCrWENpGM18/s72-c/output.JPG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-886762497320902787</id><published>2011-09-18T18:56:00.000-07:00</published><updated>2022-06-15T01:12:46.352-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="cloud computing"/><category scheme="http://www.blogger.com/atom/ns#" term="cloud computing companies"/><category scheme="http://www.blogger.com/atom/ns#" term="cloud computing providers"/><category scheme="http://www.blogger.com/atom/ns#" term="cloud computing wiki"/><category scheme="http://www.blogger.com/atom/ns#" term="how cloud computing works"/><category scheme="http://www.blogger.com/atom/ns#" term="what is cloud computing"/><title type='text'>Cloud computing-how it works &amp; providers</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
If you are looking for the information about cloud
computing, how cloud computing works, what is cloud computing or cloud
computing companies or providers, you are at right place here as you will find
a thorough knowledge about cloud computing in this post. &lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;table align=&quot;center&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;margin-left: auto; margin-right: auto; text-align: center;&quot;&gt;&lt;tbody&gt;
&lt;tr&gt;&lt;td style=&quot;text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjJwk9GTFA_A6M7btszlA699hMqMmdMC_PRd33iuJQB7PCzUFhNEwzs217LbMMJn6FZaCKRs-N9Bx-CutdRkGOvX677ggPfVKMW9a1Uh7enbXNUiQI2kfMaUDQV1JV1RYfn7zyuMnED72E/s1600/Cloud-Computing.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;169&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjJwk9GTFA_A6M7btszlA699hMqMmdMC_PRd33iuJQB7PCzUFhNEwzs217LbMMJn6FZaCKRs-N9Bx-CutdRkGOvX677ggPfVKMW9a1Uh7enbXNUiQI2kfMaUDQV1JV1RYfn7zyuMnED72E/s320/Cloud-Computing.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&gt;how cloud computing works&lt;/td&gt;&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;b&gt;What is cloud computing or How Cloud Computing Works? &lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Suppose if you&#39;re an IT manager in a large company. Your duty
is to make sure that all of your employees have the suitable hardware and
software they need to complete their tasks. If you buy computers for each
employee, it would be difficult as you have to purchase software license also. The
situation gets worse if your company has planned a massive hiring. You will
lose your sleep. &lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
To overcome this situation, there is a solution called
“Cloud Computing”. If you implement cloud computing in your organization, there
will be only one application installed on the systems. Each employee need to
use the application to log on to a web based service that hosts al the programs
your employee need. Each employee will then use only his or her specific
application and work. You will have to take services of cloud computing
providers or cloud computing companies. The remote machines owned by cloud
computing providers would run everything from spreadsheets, word processing,
emails to complex data analysis software.&lt;span&gt;&amp;nbsp;
&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
So we can define cloud computing as &lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;i&gt;Cloud computing&amp;nbsp;means “To use multiple&amp;nbsp;servers via
a digital network, as if they are a single computer.&amp;nbsp;Quite often, the
services provided are thought of a part of cloud computing”&lt;/i&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
In a cloud computing scenario, there is a major workload transfer.
Local systems do not have to do all the heavy lifting when it comes to running
applications. The interconnected computers that make up the cloud handle them
instead. Software and hardware demands on the clients’ or users’ side decrease.
The only thing that a clients’ computer should be able to run is the cloud
computing system&#39;s&amp;nbsp;interface software, which will be as simple as a Web
browser. The rest of the things are taken care by cloud&#39;s network &lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
If you think that you have not used cloud computing yet,
think again as we all use cloud computing everyday. Here’s the example: &lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
If you have an e-mail account with a Web-based e-mail
service like Gmail, Hotmail, Yahoo! Mail, then you have used cloud computing.
Instead of running an e-mail program like Microsoft Outlook or Outlook Express on
your computer, you simply logon to e-mail servers remotely. The data, software
and storage for your email account is not kept on your computer rather it
resides on the email service provider’s computer cloud. &lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiuzfpeyqqrzVH8v3oplNWCTmwAbE9N20zrEvLSx2vnYtrc3ZkA9PhkomFl42hTuDZggCp8CgWChy9P8PUoiLfiMZgooCaxqMCMdvXHOismQUkHI4E2CphGUwDXWxzJgGS0HX9F6_ykCVQ/s1600/Gmail-Google-Mails.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;192&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiuzfpeyqqrzVH8v3oplNWCTmwAbE9N20zrEvLSx2vnYtrc3ZkA9PhkomFl42hTuDZggCp8CgWChy9P8PUoiLfiMZgooCaxqMCMdvXHOismQUkHI4E2CphGUwDXWxzJgGS0HX9F6_ykCVQ/s320/Gmail-Google-Mails.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Normally a&amp;nbsp;web server&amp;nbsp;runs as a single computer or
a group of privately owned computers without a cloud. The computers are capable
enough to serve a given amount of requests per minute. The computers can do so
with a certain amount of latency per request. If a website or&amp;nbsp;web application&amp;nbsp;suddenly
becomes popular, and the amount of requests become large than the web server
can handle, the response time of the requested pages will be increased due to
overloading. While in case of in times of low load much of the capacity will go
unused. In these cases cloud computing is the best solution to save
infrastructure, cost and time. &lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
If a website,&amp;nbsp;web application or service is hosted in a
cloud, additional processing and compute power is available from the cloud
provider. The website would share those servers with probably thousands of
other websites of varying size and memory. In case if the website suddenly
becomes popular, the cloud can automatically direct more individual computers
to work to serve pages for the site, and more money is paid for the extra
usage. If it becomes unpopular, however, the amount of money due will be less.
Cloud computing is popular for its pay-as-you-go pricing model.&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;b&gt;List of Cloud Computing Companies or cloud computing
providers&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;
&lt;table cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;float: right; margin-left: 1em; text-align: right;&quot;&gt;&lt;tbody&gt;
&lt;tr&gt;&lt;td style=&quot;text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg7IE-EUdgg2fKFpfcN0uStahJQLVxhGXiTWEoJP5qIH7b27AONzzyBCMOLaQVVLEGUzrvxl4JQN1nS_-hITC1qarL5kzwZN7zgaO5jF6BAY1PYIE7pOgTuYHr65GdVToY4N7zdJaAqlmk/s1600/Cloud-Computing-Companies.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: right; margin-bottom: 1em; margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;227&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg7IE-EUdgg2fKFpfcN0uStahJQLVxhGXiTWEoJP5qIH7b27AONzzyBCMOLaQVVLEGUzrvxl4JQN1nS_-hITC1qarL5kzwZN7zgaO5jF6BAY1PYIE7pOgTuYHr65GdVToY4N7zdJaAqlmk/s320/Cloud-Computing-Companies.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&gt;Cloud computing providers&lt;/td&gt;&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
37Signals&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Adaptive Computing&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Amazon&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Appirio&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Appistry&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Apptix&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
AppZero&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Arjuna&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Astadia&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Basic Gov&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Bluewolf&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Caspio&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Citrix&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Cloud.com&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Cloudant&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Cloudera&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
CloudShare&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
CloudSwitch&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Clustercorp&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
CohesiveFT&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Constant Contact&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Cordys&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Crosscheck Networks&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Datapipe&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Egnyte&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Engine Yard&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Enomaly&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
enStratus&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Equinix&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Eucalyptus&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Flexiant&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
FreshBooks&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
GigaSpaces&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Gladinet&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
GoGrid&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
GoodData&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Google Apps&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
GreenQloud&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
GridCentric&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Hosting.com&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
iCloud&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Imonggo&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Intacct&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Intalio&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Intuit&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Jive Software&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Joyent&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
JumpBox&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Kaavo&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
LayeredTech&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Model Metrics&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Nasuni&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Navajo Systems&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Navisite&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
NetSuite&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Nimbula&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Nimbus&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Nimsoft&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Nirvanix&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Nubifer&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Okta&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
OpenNebula&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
PanTerra Networks&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Parallels&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Practice Fusion&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Rackspace&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Red Hat&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Relational Networks&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
ReliaCloud&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Rightscale&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
rPath&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Salesforce.com&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Savvis&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
SoftLayer&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
SuccessFactors&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Sungard&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Symplified&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Terremark Worldwide&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Tropo&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Twilio&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Vertica&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Virtual &lt;st1:state w:st=&quot;on&quot;&gt;&lt;st1:place w:st=&quot;on&quot;&gt;Ark&lt;/st1:place&gt;&lt;/st1:state&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
VMWare&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Voxeo&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Whamcloud&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Workbooks&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Workday&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Zoho&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Zuora&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Learn What is cloud computing in this video&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;object width=&quot;320&quot; height=&quot;266&quot; class=&quot;BLOGGER-youtube-video&quot; classid=&quot;clsid:D27CDB6E-AE6D-11cf-96B8-444553540000&quot; codebase=&quot;http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0&quot; data-thumbnail-src=&quot;http://3.gvt0.com/vi/ae_DKNwK_ms/0.jpg&quot;&gt;&lt;param name=&quot;movie&quot; value=&quot;http://www.youtube.com/v/ae_DKNwK_ms&amp;fs=1&amp;source=uds&quot; /&gt;
&lt;param name=&quot;bgcolor&quot; value=&quot;#FFFFFF&quot; /&gt;
&lt;embed width=&quot;320&quot; height=&quot;266&quot;  src=&quot;http://www.youtube.com/v/ae_DKNwK_ms&amp;fs=1&amp;source=uds&quot; type=&quot;application/x-shockwave-flash&quot;&gt;&lt;/embed&gt;&lt;/object&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;o:p&gt;If you want to know more about cloud computing at Wikipedia go to &lt;a href=&quot;http://en.wikipedia.org/wiki/Cloud_computing&quot;&gt;Cloud computing @ Wiki&lt;/a&gt;&lt;/o:p&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
I hope you enjoyed this post about cloud computing. Now
spread this knowledge to your friends and family. Share this post!!!&amp;nbsp;&lt;/div&gt;
&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/886762497320902787/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/09/cloud-computing-how-it-works-providers.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/886762497320902787'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/886762497320902787'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/09/cloud-computing-how-it-works-providers.html' title='Cloud computing-how it works &amp; providers'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjJwk9GTFA_A6M7btszlA699hMqMmdMC_PRd33iuJQB7PCzUFhNEwzs217LbMMJn6FZaCKRs-N9Bx-CutdRkGOvX677ggPfVKMW9a1Uh7enbXNUiQI2kfMaUDQV1JV1RYfn7zyuMnED72E/s72-c/Cloud-Computing.jpg" height="72" width="72"/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-267838689109700190</id><published>2011-09-06T18:42:00.000-07:00</published><updated>2022-06-15T01:12:46.318-07:00</updated><title type='text'>What is High Level Language</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
If you are wondering what is High Level Language and want to know the definition of HLL. Just see the video&lt;br /&gt;
&lt;div&gt;
&lt;object data=&quot;http://cdn-www.expertvillage.com/player.swf?cacheBuster=755805612&amp;amp;flv=164310_what-definition-high-level-language&quot; height=&quot;424&quot; id=&quot;ev_player&quot; type=&quot;application/x-shockwave-flash&quot; width=&quot;491&quot;&gt;&lt;param name=&quot;allowScriptAccess&quot; value=&quot;always&quot; /&gt;
&lt;param name=&quot;allowFullScreen&quot; value=&quot;true&quot; /&gt;
&lt;param name=&quot;movie&quot; value=&quot;http://cdn-www.expertvillage.com/player.swf?cacheBuster=755805612&amp;flv=164310_what-definition-high-level-language&quot; /&gt;
&lt;param name=&quot;wmode&quot; value=&quot;transparent&quot; /&gt;
&lt;/object&gt;&lt;br /&gt;
&lt;br /&gt;
I hope you learned from this tutorial. Now spread this knowledge&lt;/div&gt;
&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/267838689109700190/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/09/what-is-high-level-language.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/267838689109700190'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/267838689109700190'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/09/what-is-high-level-language.html' title='What is High Level Language'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-502489507863787330</id><published>2011-09-03T07:05:00.000-07:00</published><updated>2022-06-15T01:12:46.340-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="computer quiz"/><category scheme="http://www.blogger.com/atom/ns#" term="computer quiz questions and answers"/><category scheme="http://www.blogger.com/atom/ns#" term="information technology"/><category scheme="http://www.blogger.com/atom/ns#" term="information technology quiz"/><category scheme="http://www.blogger.com/atom/ns#" term="IT quiz"/><title type='text'>online information technology quiz-questions and answers</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
Are you looking for online information technology quiz? If yes, go ahead and find an interesting online IT Quiz. Answer the questions &amp;nbsp;and know where you stand. Check your score at the end of &amp;nbsp;the quiz. Do not cheat. Be honest. &amp;nbsp;So enjoy the Quiz&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;div style=&quot;background: #666 url(&#39;http://x.hubpages.com/x/quiz.png&#39;) no-repeat scroll 24px 10px; height: 50px; width: 242px;&quot;&gt;
&lt;/div&gt;
&lt;div style=&quot;border-left: 1px solid #ccc; border-right: 1px solid #ccc; width: 240px;&quot;&gt;
&lt;embed align=&quot;middle&quot; allowscriptaccess=&quot;always&quot; flashvars=&quot;id=26424&quot; height=&quot;336&quot; loop=&quot;false&quot; play=&quot;true&quot; pluginspage=&quot;http://www.adobe.com/go/getflashplayer&quot; quality=&quot;high&quot; src=&quot;http://hubpages.com/quizwidget/Widget.swf&quot; type=&quot;application/x-shockwave-flash&quot; width=&quot;240&quot;&gt;&lt;/embed&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #666666; text-align: right; width: 242px;&quot;&gt;
&lt;a href=&quot;http://programming.info-daddy.com/&quot; style=&quot;color: white; display: block; font: bold 12px Arial, Helvetica, Sans-Serif; padding: 6px 10px;&quot;&gt;Take this IT Quiz and know how much you know IT world&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Now when you have taken the quiz, you have known yourself whether you are an IT geek or not. Congratulations to you if you have scored more than 90%.&lt;/div&gt;
&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/502489507863787330/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/09/online-information-technology-quiz.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/502489507863787330'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/502489507863787330'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/09/online-information-technology-quiz.html' title='online information technology quiz-questions and answers'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-1524105287789672245</id><published>2011-08-19T17:35:00.000-07:00</published><updated>2022-06-15T01:12:46.382-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="binary to decimal conversion"/><category scheme="http://www.blogger.com/atom/ns#" term="decimal to binary conversion"/><category scheme="http://www.blogger.com/atom/ns#" term="how to convert binary to decimal"/><category scheme="http://www.blogger.com/atom/ns#" term="how to convert decimal to binary"/><title type='text'>how to convert decimal to binary and binary to decimal</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;b&gt;HOW TO CONVERT DECIMAL TO BINARY AND BINARY TO DECIMAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
For converting a number from decimal to binary we use
repeated division by 2 method. We continue the repeated division by 2 till we
get the number less than 2. For example:&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;b&gt;Repeated division method:&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Divide the decimal number by 2 and store remainder at one
place. Continue this process till the decimal number is less than 2. Finally
write the remainders in reverse order: &lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
You will understand this concept by this example:&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span&gt;&amp;nbsp;&lt;/span&gt;If we want to convert
decimal number 65 to binary, we can do this as following:&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoTableGrid&quot; style=&quot;border-collapse: collapse; border: none; mso-border-alt: solid windowtext .5pt; mso-border-insideh: .5pt solid windowtext; mso-border-insidev: .5pt solid windowtext; mso-padding-alt: 0in 5.4pt 0in 5.4pt; mso-table-layout-alt: fixed; mso-yfti-tbllook: 480;&quot;&gt;
 &lt;tbody&gt;
&lt;tr&gt;
  &lt;td style=&quot;border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
Divisor 2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-left: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
Decimal Number and quotients&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-left: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
Remainder&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
65&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
&lt;!--[if gte vml 1]&gt;&lt;v:line id=&quot;_x0000_s1026&quot; style=&#39;position:absolute;
   flip:y;z-index:1;mso-position-horizontal-relative:text;
   mso-position-vertical-relative:text&#39; from=&quot;12.6pt,13.4pt&quot; to=&quot;12.6pt,110.2pt&quot;&gt;
   &lt;v:stroke endarrow=&quot;block&quot;/&gt;
  &lt;/v:line&gt;&lt;![endif]--&gt;&lt;!--[if !vml]--&gt;&lt;span style=&quot;height: 132px; margin-left: 11px; margin-top: 16px; mso-ignore: vglayout; position: absolute; width: 12px; z-index: 1;&quot;&gt;&lt;img height=&quot;132&quot; src=&quot;file:///C:/DOCUME~1/devsir/LOCALS~1/Temp/msohtml1/01/clip_image001.gif&quot; v:shapes=&quot;_x0000_s1026&quot; width=&quot;12&quot; /&gt;&lt;/span&gt;&lt;!--[endif]--&gt;&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
32&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
1&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
16&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
0&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
8&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
0&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
4&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
0&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
0&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
1&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
0&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
0&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
1&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Now writing the remainders in reverse order we get 1000001&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
So Decimal number 65 is 1000001 in binary&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
One more example:&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Convert 45 from decimal to binary&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;span&gt;&amp;nbsp; &lt;/span&gt;&lt;/div&gt;
&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoTableGrid&quot; style=&quot;border-collapse: collapse; border: none; mso-border-alt: solid windowtext .5pt; mso-border-insideh: .5pt solid windowtext; mso-border-insidev: .5pt solid windowtext; mso-padding-alt: 0in 5.4pt 0in 5.4pt; mso-table-layout-alt: fixed; mso-yfti-tbllook: 480;&quot;&gt;
 &lt;tbody&gt;
&lt;tr&gt;
  &lt;td style=&quot;border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
Divisor 2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-left: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
Decimal Number and quotients&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-left: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
Remainder&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
45&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
22&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
&lt;!--[if gte vml 1]&gt;&lt;v:line id=&quot;_x0000_s1027&quot; style=&#39;position:absolute;
   flip:y;z-index:2;mso-position-horizontal-relative:text;
   mso-position-vertical-relative:text&#39; from=&quot;18pt,-.75pt&quot; to=&quot;18pt,84.3pt&quot;&gt;
   &lt;v:stroke endarrow=&quot;block&quot;/&gt;
  &lt;/v:line&gt;&lt;![endif]--&gt;&lt;!--[if !vml]--&gt;&lt;span style=&quot;mso-ignore: vglayout; position: relative; z-index: 2;&quot;&gt;&lt;span style=&quot;height: 116px; left: 18px; position: absolute; top: -3px; width: 12px;&quot;&gt;&lt;img height=&quot;116&quot; src=&quot;file:///C:/DOCUME~1/devsir/LOCALS~1/Temp/msohtml1/01/clip_image002.gif&quot; v:shapes=&quot;_x0000_s1027&quot; width=&quot;12&quot; /&gt;&lt;/span&gt;&lt;/span&gt;&lt;!--[endif]--&gt;1&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
11&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
0&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
5&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
1&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
1&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
1&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
0&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;tr&gt;
  &lt;td style=&quot;border-top: none; border: solid windowtext 1.0pt; mso-border-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 59.4pt;&quot; valign=&quot;top&quot; width=&quot;79&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
2&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 2.25in;&quot; valign=&quot;top&quot; width=&quot;216&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
0&lt;/div&gt;
&lt;/td&gt;
  &lt;td style=&quot;border-bottom: solid windowtext 1.0pt; border-left: none; border-right: solid windowtext 1.0pt; border-top: none; mso-border-alt: solid windowtext .5pt; mso-border-left-alt: solid windowtext .5pt; mso-border-top-alt: solid windowtext .5pt; padding: 0in 5.4pt 0in 5.4pt; width: 1.0in;&quot; valign=&quot;top&quot; width=&quot;96&quot;&gt;
  &lt;div class=&quot;MsoNormal&quot;&gt;
1&lt;/div&gt;
&lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Writing the remainders in reverse order we get 101101 which
is binary equivalent of 45.&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Now if we want to convert vice versa i.e. from binary to
decimal, we can use the following method:&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
Take each digit of binary number from right to left and
multiply the digit with &lt;span style=&quot;font-size: 24.0pt;&quot;&gt;2&lt;sup&gt;n&lt;/sup&gt; &lt;/span&gt;in&lt;span style=&quot;font-size: 24.0pt;&quot;&gt; &lt;/span&gt;increasing order.&lt;span style=&quot;font-size: 24.0pt;&quot;&gt;
&lt;/span&gt;Here n starts with 0 and increases by 1. Finally add the individual
terms and get the decimal number. You will understand this concept by the
following example:&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;b&gt;Converting 101101 to decimal &lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;b&gt;&lt;span style=&quot;font-size: 16.0pt;&quot;&gt;1x2&lt;sup&gt;5&lt;/sup&gt;+0x2&lt;sup&gt;4&lt;/sup&gt;+1x2&lt;sup&gt;3&lt;/sup&gt;+1x2&lt;sup&gt;2&lt;/sup&gt;+0x2&lt;sup&gt;1&lt;/sup&gt;+1x2&lt;sup&gt;0&lt;o:p&gt;&lt;/o:p&gt;&lt;/sup&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;b&gt;&lt;sup&gt;&lt;span style=&quot;font-size: 16.0pt;&quot;&gt;=32+0+8+4+0+1&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;b&gt;&lt;sup&gt;&lt;span style=&quot;font-size: 16.0pt;&quot;&gt;=45&lt;/span&gt;&lt;/sup&gt;&lt;/b&gt;&lt;b&gt;&lt;span style=&quot;font-size: 16.0pt;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
So the decimal equivalent of 101101 is 45&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
I hope you have understood the process of converting decimal
to binary and vice versa. Your comments are welcome&lt;/div&gt;
&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/1524105287789672245/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/how-to-convert-decimal-to-binary-and.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/1524105287789672245'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/1524105287789672245'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/how-to-convert-decimal-to-binary-and.html' title='how to convert decimal to binary and binary to decimal'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-3474418888681208246</id><published>2011-08-18T06:34:00.001-07:00</published><updated>2022-06-15T01:12:46.416-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="c program to quick sort numbers"/><category scheme="http://www.blogger.com/atom/ns#" term="Quick sort program in C++"/><title type='text'>Quick sort program in C++</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;//Quick sort program in C++&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;process.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void quickSort(int numbers[], int array_size);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void q_sort(int numbers[], int left, int right);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int numbers[5];&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int main()&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;clrscr();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;int i,n;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;cout&amp;lt;&amp;lt;&quot;How many numbers you want to sort: &quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;cin&amp;gt;&amp;gt;n;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;cout&amp;lt;&amp;lt;&quot;Enter &quot;&amp;lt;&amp;lt;n&amp;lt;&amp;lt;&quot; numbers.\n&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;for (i = 0; i&amp;lt;n; i++)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; cin&amp;gt;&amp;gt;numbers[i];&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;//perform quick sort on array&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;q_sort(numbers,0,n-1);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;cout&amp;lt;&amp;lt;&quot;Numbers are sorted\n&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;for (i = 0; i&amp;lt;n; i++)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; cout&amp;lt;&amp;lt;numbers[i]&amp;lt;&amp;lt;&quot; &amp;nbsp; &quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;getch();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;return(0);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;// Function to sort&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void q_sort(int numbers[], int left, int right)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;int pivot, l_hold, r_hold;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;l_hold = left;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;r_hold = right;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;pivot = numbers[left];&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;while (left &amp;lt; right)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; while ((numbers[right] &amp;gt;= pivot) &amp;amp;&amp;amp; (left &amp;lt; right))&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; right--;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; if (left != right)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; numbers[left] = numbers[right];&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; left++;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; while ((numbers[left] &amp;lt;= pivot) &amp;amp;&amp;amp; (left &amp;lt; right))&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; left++;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; if (left != right)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp;numbers[right] = numbers[left];&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp;right--;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;numbers[left] = pivot;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;pivot = left;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;left = l_hold;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;right = r_hold;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;if (left &amp;lt; pivot)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; q_sort(numbers, left, pivot-1);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;if (right &amp;gt; pivot)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; q_sort(numbers, pivot+1, right);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/3474418888681208246/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/quick-sort-program-in-c.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/3474418888681208246'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/3474418888681208246'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/quick-sort-program-in-c.html' title='Quick sort program in C++'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-8253458664008627566</id><published>2011-08-18T06:30:00.000-07:00</published><updated>2022-06-15T01:12:46.472-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C++ program to convert decimal to binary"/><title type='text'>C++ program to convert decimal to binary</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;//program to find binary equivalent of a decimal no.&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void main()&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;clrscr();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int arr[10];&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int ctr=0;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;long int n,quo=0,rem=0;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;Enter A No. &quot;&amp;lt;&amp;lt;endl;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cin&amp;gt;&amp;gt;n;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;for(quo=n;quo!=0;ctr++)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;rem=quo%2;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;arr[ctr]=rem;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;quo=quo/2;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;Binary Equivalent Of &quot;&amp;lt;&amp;lt;n&amp;lt;&amp;lt;&quot; is-----&amp;gt; &quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;for(ctr=ctr-1;ctr&amp;gt;=0;ctr--)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;arr[ctr];&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;getch();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}//end main&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/8253458664008627566/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/c-program-to-convert-decimal-to-binary.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/8253458664008627566'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/8253458664008627566'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/c-program-to-convert-decimal-to-binary.html' title='C++ program to convert decimal to binary'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-2828364175316103203</id><published>2011-08-18T06:28:00.000-07:00</published><updated>2022-06-15T01:12:46.409-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C++ program to convert binary to decimal"/><title type='text'>C++ program to convert binary to decimal</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
C++ program to convert binary to decimal&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;//program to convert a binary no. into decimal no.&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;math.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void main()&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{clrscr();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;long int n,x;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;Please enter a binary no. &quot;&amp;lt;&amp;lt;endl;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cin&amp;gt;&amp;gt;n;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;x=n;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int rem=0,sum=0;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;for(int ctr=0;n&amp;gt;0;ctr++)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{ rem=n%10;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; rem=rem*(pow(2,ctr));&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; sum=sum+rem;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; n=n/10;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;Decimal Equivalent of &quot;&amp;lt;&amp;lt;x&amp;lt;&amp;lt;&quot; is &quot;&amp;lt;&amp;lt;sum&amp;lt;&amp;lt;endl;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;getch();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}//end main&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/2828364175316103203/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/c-program-to-convert-binary-to-decimal.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/2828364175316103203'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/2828364175316103203'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/c-program-to-convert-binary-to-decimal.html' title='C++ program to convert binary to decimal'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-4361377730142964618</id><published>2011-08-17T05:07:00.000-07:00</published><updated>2022-06-15T01:12:46.438-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C++ program to convert numbers to words"/><category scheme="http://www.blogger.com/atom/ns#" term="digits to words"/><category scheme="http://www.blogger.com/atom/ns#" term="numbers to words program"/><title type='text'>C++ program to convert numbers to words</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
If you are looking for a C++ program to convert numbers to words, you can find a good C++ program here which can convert numbers to words up to 5 digits.&lt;br /&gt;
&lt;br /&gt;
here is the program:&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void single(int);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void ten2ninety(int);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void elev2nine(int);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void dig2word(int);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void main()&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;clrscr();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int a;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;\n Enter a number\n&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cin&amp;gt;&amp;gt;a;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;dig2word(a);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;getch();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void dig2word(int y)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int s=y,ctr=0,ldig,sdig,l2dig,l3dig,l3rddig;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;while(y&amp;gt;0)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;y=y/10;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;++ctr;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;if(ctr==1)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; single(s);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; return;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;else if(ctr==2)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; ldig=s%10;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; s=s/10;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; sdig=s%10;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp;if(ldig==0)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp; &amp;nbsp;ten2ninety(sdig);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp; &amp;nbsp;return;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp;if(sdig==1)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp;elev2nine(ldig);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp;return;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; ten2ninety(sdig);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; single(ldig);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; return;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;else if(ctr==3)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;l2dig=s%100;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;s=s/100;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;sdig=s%10;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;if(l2dig==0)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; single(sdig);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; cout&amp;lt;&amp;lt;&quot; Hundred&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; return;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;else&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; single(sdig);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; cout&amp;lt;&amp;lt;&quot; Hundred&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; dig2word(l2dig);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; return;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;else if(ctr==4)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;l3dig=s%1000;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;s=s/1000;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;sdig=s%10;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;if(l3dig==0)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; single(sdig);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; cout&amp;lt;&amp;lt;&quot; Thousand&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; return;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;else&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; single(sdig);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; cout&amp;lt;&amp;lt;&quot; Thousand&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; dig2word(l3dig);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; return;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; else if(ctr==5)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;l2dig=s%100;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;l3dig=s%1000;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;s=s/100;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;l3rddig=s%10;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;s=s/10;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;if(l2dig==0&amp;amp;&amp;amp;l3rddig==0)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; dig2word(s);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; cout&amp;lt;&amp;lt;&quot;Thousand&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; return;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;dig2word(s);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;cout&amp;lt;&amp;lt;&quot;Thousand&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;dig2word(l3dig);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;return;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void single(int x)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp;switch(x)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 0:cout&amp;lt;&amp;lt;&quot; Zero &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 1:cout&amp;lt;&amp;lt;&quot; One &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 2:cout&amp;lt;&amp;lt;&quot; Two &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 3:cout&amp;lt;&amp;lt;&quot; Three &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 4:cout&amp;lt;&amp;lt;&quot; Four &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 5:cout&amp;lt;&amp;lt;&quot; Five &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 6:cout&amp;lt;&amp;lt;&quot; Six &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 7:cout&amp;lt;&amp;lt;&quot; Seven &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 8:cout&amp;lt;&amp;lt;&quot; Eight &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 9:cout&amp;lt;&amp;lt;&quot; Nine &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void elev2nine(int x)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp;switch(x)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 1:cout&amp;lt;&amp;lt;&quot; Eleven &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 2:cout&amp;lt;&amp;lt;&quot; Tweleve &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 3:cout&amp;lt;&amp;lt;&quot; Thirteen &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 4:cout&amp;lt;&amp;lt;&quot; Fourteen &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 5:cout&amp;lt;&amp;lt;&quot; Fifteen &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 6:cout&amp;lt;&amp;lt;&quot; Sixteen &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 7:cout&amp;lt;&amp;lt;&quot; Seventeen &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 8:cout&amp;lt;&amp;lt;&quot; Eighteen &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 9:cout&amp;lt;&amp;lt;&quot; Nineteen &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void ten2ninety(int x)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp;switch(x)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 1:cout&amp;lt;&amp;lt;&quot; Ten &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 2:cout&amp;lt;&amp;lt;&quot; Twenty &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 3:cout&amp;lt;&amp;lt;&quot; Thirty &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 4:cout&amp;lt;&amp;lt;&quot; Forty &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 5:cout&amp;lt;&amp;lt;&quot; Fifty &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 6:cout&amp;lt;&amp;lt;&quot; Sixty &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 7:cout&amp;lt;&amp;lt;&quot; Seventy &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 8:cout&amp;lt;&amp;lt;&quot; Eighty &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; case 9:cout&amp;lt;&amp;lt;&quot; Ninety &quot;;break;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&lt;br /&gt;
The above program works best for integer limit that means up to 32767 but if you want up to 99999. convert all &quot;int&quot; to &quot;long int&quot;&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/4361377730142964618/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/c-program-to-convert-numbers-to-words.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/4361377730142964618'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/4361377730142964618'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/c-program-to-convert-numbers-to-words.html' title='C++ program to convert numbers to words'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-8345271675531041362</id><published>2011-08-17T04:48:00.001-07:00</published><updated>2022-06-15T01:12:46.481-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="armstrong numbers program in C++"/><category scheme="http://www.blogger.com/atom/ns#" term="C++ program to print armstrong numbers between 1 to 1000"/><title type='text'>C++ program to print armstrong numbers between 1 to 1000</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;br /&gt;
Are you looking for the armstrong numbers program in C++? if yes, read up on to know and learn the armstrong numbers program in C++.&lt;br /&gt;
&lt;br /&gt;
What is armstrog number?&lt;br /&gt;
An armstrong number is that number whose digits when raised to power 3 and added produce the number itself for example:&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
153 = 1&lt;sup&gt;3&lt;/sup&gt; + 5&lt;sup&gt;3&lt;/sup&gt; + 3&lt;sup&gt;3&lt;/sup&gt;&lt;/div&gt;
&lt;br /&gt;
The following program prints armstrong numbers between 1 to 1000.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void arm(int);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void main()&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;for(int
i=1;i&amp;lt;=1000;++i)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;arm(i);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void arm(int a)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int b,rem,sum=0;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;b=a;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;while(a&amp;gt;0)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;rem=a%10;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;sum=sum+(rem
* rem * rem);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;a=a/10;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;if(sum==b)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;Armstrong Num &quot;&amp;lt;&amp;lt;b&amp;lt;&amp;lt;&quot;\n&quot;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;div class=&quot;MsoNormal&quot;&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 17px;&quot;&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/sup&gt;&lt;/div&gt;
&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/8345271675531041362/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/c-program-to-print-armstrong-numbers.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/8345271675531041362'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/8345271675531041362'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/c-program-to-print-armstrong-numbers.html' title='C++ program to print armstrong numbers between 1 to 1000'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-2021578788353222171</id><published>2011-08-17T04:16:00.000-07:00</published><updated>2022-06-15T01:12:46.397-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C++ program to find lcm and hcf"/><category scheme="http://www.blogger.com/atom/ns#" term="lcm and hcf program in C++"/><title type='text'>C++ program to find lcm and hcf</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica; font-size: 12px; line-height: 21px;&quot;&gt;If you are looking for a C++ program to find lcm and hcf of 2 numbers, you will find the program here. The following program accepts 2 numbers and finds lcm and hcf of those numbers.&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #333333; font-family: Arial, Helvetica;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 12px; line-height: 21px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
Here is the program:&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int lcm(int,int);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int hcf(int,int);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void main()&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;clrscr();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int a,b,l,h;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;\n Enter 2 numbers\n&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cin&amp;gt;&amp;gt;a&amp;gt;&amp;gt;b;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;l=lcm(a,b);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;h=hcf(a,b);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;LCM:&quot;&amp;lt;&amp;lt;l&amp;lt;&amp;lt;&quot;\t&quot;&amp;lt;&amp;lt;&quot;HCF:&quot;&amp;lt;&amp;lt;h;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;getch();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int lcm(int x,int y)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; int i,big;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp;big=(x&amp;gt;y)?x:y;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;for(i=big;i&amp;lt;=x*y;++i)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;		&lt;/span&gt;if(i%x==0&amp;amp;&amp;amp;i%y==0)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;		&lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;		&lt;/span&gt; return i;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;		&lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;return 0;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int hcf(int x,int y)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; int i,small,max=1;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; small=(x&amp;lt;y)?x:y;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;for(i=1;i&amp;lt;=small;++i)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;		&lt;/span&gt;if(x%i==0&amp;amp;&amp;amp;y%i==0)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;		&lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;		&lt;/span&gt;max=i;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;		&lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;return max;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/2021578788353222171/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/c-program-to-find-lcm-and-hcf.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/2021578788353222171'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/2021578788353222171'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/c-program-to-find-lcm-and-hcf.html' title='C++ program to find lcm and hcf'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-8689372228535244660</id><published>2011-08-17T04:12:00.000-07:00</published><updated>2022-06-15T01:12:46.494-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C++ program to print pythagoran triplets between 1 to 1000"/><category scheme="http://www.blogger.com/atom/ns#" term="pytha goran triplets program in C++"/><title type='text'>C++ program to print pythagoran triplets between 1 to 1000</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;br /&gt;
If you are looking for a C++ program which prints pythagoran triplets between 1 to 1000, you will find the program here.&lt;br /&gt;
&lt;br /&gt;
What is pythagoran triplet?&lt;br /&gt;
A group of 3 numbers a,b,c where&amp;nbsp;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;c&lt;sup&gt;2&lt;/sup&gt;=a&lt;sup&gt;2&lt;/sup&gt;+b&lt;sup&gt;2.&lt;/sup&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;sup&gt;&lt;br /&gt;
&lt;/sup&gt;&lt;/span&gt;&lt;br /&gt;
&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;Here&amp;nbsp;&lt;/span&gt;&lt;/sup&gt;&lt;sup&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: small;&quot;&gt;is the program:&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/sup&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void pytha(long int,long int,long int);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void main()&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{ &amp;nbsp; clrscr();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&amp;nbsp; &amp;nbsp; long int i,j,k;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;for(i=1;i&amp;lt;=100;++i)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; for(j=1;j&amp;lt;i;++j)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; {&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp; &amp;nbsp;for(k=1;k&amp;lt;j;++k)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp; &amp;nbsp;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;		&lt;/span&gt;pytha(i,j,k);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; &amp;nbsp; &amp;nbsp;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt; }&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;span class=&quot;Apple-tab-span&quot; style=&quot;white-space: pre;&quot;&gt;	&lt;/span&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;getch();&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void pytha(long int a,long int b,long int c)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;if((a*a)==(b*b)+(c*c))&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot; Pythagoran triplets--&amp;gt;&quot;&amp;lt;&amp;lt;a&amp;lt;&amp;lt;&quot; &quot;&amp;lt;&amp;lt;b&amp;lt;&amp;lt;&quot; &quot;&amp;lt;&amp;lt;c&amp;lt;&amp;lt;&quot;\n&quot;;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/8689372228535244660/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/c-program-to-print-pythagoran-triplets.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/8689372228535244660'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/8689372228535244660'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/08/c-program-to-print-pythagoran-triplets.html' title='C++ program to print pythagoran triplets between 1 to 1000'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-5848822663140930292</id><published>2011-02-09T05:40:00.000-08:00</published><updated>2022-06-15T01:12:46.459-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="call by value and call by reference c++"/><category scheme="http://www.blogger.com/atom/ns#" term="What is call by value and call by reference in c++"/><category scheme="http://www.blogger.com/atom/ns#" term="What is difference between call by value and call by reference in c++"/><title type='text'>call by value and call by reference c++</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
Are you looking for call by value and call by reference in c++? Do you want to understand the working of call by value and call by reference in c++? Do you want to understand the concepts of call by value and call by reference in c++? If yes, read ahead.&lt;br /&gt;
&lt;br /&gt;
What is call by value and call by reference in c++?&lt;br /&gt;
&lt;br /&gt;
Call by value and call by reference are two mechanisms in c++ to invoke functions with parameters as value or reference. Both the concepts have a different working.&lt;br /&gt;
&lt;br /&gt;
What is difference between call by value and call by reference in c++? How call by value and call by reference work in c++?&lt;br /&gt;
&lt;br /&gt;
In call by value mechanism, parameters are passed by value. It means that the called function makes a copy of parameters and these copied values have nothing to do with original values of parameters sent by calling function. If you make changes in the values of parameters of called function, the changes will not be reflected back in the values of parameters of calling function because the called and calling function have different copies of variables at different memory locations&lt;br /&gt;
&lt;br /&gt;
In call by reference mechanism, parameters are passed by reference. It means that the called function does not make a copy of parameters sent by calling function rather called function takes the original address of parameters sent by calling function. If you make changes in the values of parameters of called function, the change will be reflected back in the values of parameters of calling function because the called and calling function share the parameters at same memory locations.&lt;br /&gt;
&lt;br /&gt;
See the working of call by value and call by reference in c++ by following programs : &lt;br /&gt;
&lt;br /&gt;
Program to display Call by value in C++&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void swap(int,int);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void main()&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int a=5,b=7;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;Value of a and b in main function before swap:&quot;&amp;lt;&amp;lt;a&amp;lt;&amp;lt;b;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;swap(a,b);&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;Value of a and b in main function after swap:&quot;&amp;lt;&amp;lt;a&amp;lt;&amp;lt;b;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;void swap(int a,int b)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;{&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;int temp;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;temp=a;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;a=b;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;b=temp;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;cout&amp;lt;&amp;lt;&quot;Value of a and b in swap function:&quot;&amp;lt;&amp;lt;a&amp;lt;&amp;lt;b;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
PROGRAM OUTPUT:&lt;br /&gt;
&lt;br /&gt;
Value of a and b in main function before swap:5 7&lt;br /&gt;
Value of a and b in swap function:7 5&lt;br /&gt;
Value of a and b in main function after swap:5 7&lt;br /&gt;
&lt;br /&gt;
Program Explanation:&lt;br /&gt;
Line 1: including header file in the program&lt;br /&gt;
Line 2: swap function prototype&lt;br /&gt;
Line 5: 2 integer variables a and b declared and initialized with values of 5 and 7 respectively&lt;br /&gt;
Line 7: Call to function swap with parameters a and b&lt;br /&gt;
Line 10-17: swap function swapping the values of a and b.&lt;br /&gt;
&lt;br /&gt;
Program to display Call by reference in C++&lt;br /&gt;
#include&lt;br /&gt;
void swap(int&amp;amp;,int&amp;amp;);&lt;br /&gt;
void main()&lt;br /&gt;
{&lt;br /&gt;
int a=5,b=7;&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;Value of a and b in main function before swap:&quot;&amp;lt;&amp;lt;a&amp;lt;&amp;lt;b;&lt;br /&gt;
swap(a,b);&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;Value of a and b in main function after swap:&quot;&amp;lt;&amp;lt;a&amp;lt;&amp;lt;b;&lt;br /&gt;
}&lt;br /&gt;
void swap(int &amp;amp;a,int &amp;amp;b)&lt;br /&gt;
{&lt;br /&gt;
int temp;&lt;br /&gt;
temp=a;&lt;br /&gt;
a=b;&lt;br /&gt;
b=temp;&lt;br /&gt;
cout&amp;lt;&amp;lt;&quot;Value of a and b in swap function:&quot;&amp;lt;&amp;lt;a&amp;lt;&amp;lt;b;&lt;br /&gt;
}&lt;br /&gt;
PROGRAM OUTPUT:&lt;br /&gt;
Value of a and b in main function before swap:5 7&lt;br /&gt;
Value of a and b in swap function:7 5&lt;br /&gt;
Value of a and b in main function after swap:7 5&lt;br /&gt;
Program Explanation:&lt;br /&gt;
Line 1: including header file in the program&lt;br /&gt;
Line 2: swap function prototype&lt;br /&gt;
Line 5: 2 integer variables a and b declared and initialized with values of 5 and 7 respectively&lt;br /&gt;
Line 7: Call to function swap with parameters a and b&lt;br /&gt;
Line 10-17: swap function taking parameters by reference.&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/5848822663140930292/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2011/02/call-by-value-and-call-by-reference-c.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/5848822663140930292'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/5848822663140930292'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2011/02/call-by-value-and-call-by-reference-c.html' title='call by value and call by reference c++'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-795135540165328047</id><published>2010-10-30T22:23:00.000-07:00</published><updated>2022-06-15T01:12:46.346-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="accept name print initials"/><category scheme="http://www.blogger.com/atom/ns#" term="c program to accept a name and print initials"/><category scheme="http://www.blogger.com/atom/ns#" term="C++ to print initials"/><category scheme="http://www.blogger.com/atom/ns#" term="convert a name to initials"/><category scheme="http://www.blogger.com/atom/ns#" term="print initials"/><title type='text'>C++ programming:program to accept your name and print initials:how to display initials:name initials sample in C</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;iframe align=&quot;left&quot; frameborder=&quot;0&quot; marginheight=&quot;0&quot; marginwidth=&quot;0&quot; scrolling=&quot;no&quot; src=&quot;http://rcm.amazon.com/e/cm?t=cprogbydevs-20&amp;amp;o=1&amp;amp;p=8&amp;amp;l=bpl&amp;amp;asins=0470317353&amp;amp;fc1=000000&amp;amp;IS2=1&amp;amp;lt1=_blank&amp;amp;m=amazon&amp;amp;lc1=0000FF&amp;amp;bc1=000000&amp;amp;bg1=FFFFFF&amp;amp;f=ifr&quot; style=&quot;align: left; height: 245px; padding-right: 10px; padding-top: 5px; width: 131px;&quot;&gt;&lt;/iframe&gt;In this tutorial, you will find a C++ program which accepts a name and prints initials for example if the input is &quot;Vidhu Vinod Chopra&quot;, program will print &quot;V.V.Chopra&quot;.&lt;/span&gt;&lt;br /&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;Following is a C++ program to accept a name and then print its initials. For Example If the input is &quot;Mohandas Karamchand Gandhi&quot;&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;This program will display M.K.Gandhi&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;Program Explanation:&lt;/span&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;Logic:&lt;/span&gt;&lt;/em&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;first&amp;nbsp;print&amp;nbsp;the first character by cout&amp;lt;&amp;lt;arr[0] and a dot by cout&amp;lt;&amp;lt;&quot;.&quot; Then a loop runs till end of string and if it finds space, the next character is printed and a dot is printed. So in the above exmple if we input Mohandas Karamchand Gandhi, the output is M.K.G. Now a loop runs in array to go back till it finds a space. Then the statement cout&amp;lt;&amp;lt;\b\b&quot; at line 22 erases 2 characters backside. It erases &quot;G.&quot; Now a loop again runs from&amp;nbsp;next character&amp;nbsp;of the the last space till the end of the string. In our example it starts from G and prints Gandhi.&lt;/span&gt;&lt;/div&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;background-color: white; color: #333333; font-size: 14px; line-height: 18px;&quot;&gt;Line 9:&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;background-color: white; color: #333333; font-size: 14px; line-height: 18px;&quot;&gt;&amp;nbsp;&lt;/span&gt;input&lt;span class=&quot;Apple-style-span&quot; style=&quot;background-color: white; color: #333333; font-size: 14px; line-height: 18px;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;background-color: white; color: #333333; font-size: 14px; line-height: 18px;&quot;&gt;through gets() because cin does not input space&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;pre class=&quot;moduleCode cpp&quot; id=&quot;code_d_8034298&quot; name=&quot;code&quot; style=&quot;background-color: white; color: #333333; font-size: 14px; font: normal normal normal 0.9em/normal &#39;Courier New&#39;, Courier, monospace; line-height: 1em; overflow-x: hidden; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; white-space: pre-wrap; width: 506px; word-wrap: break-word;&quot;&gt;&lt;ol style=&quot;text-align: left;&quot;&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;#include&amp;lt;iostream.h&amp;gt;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;#include&amp;lt;stdio.h&amp;gt;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;void main()&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;{&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;clrscr();&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;char arr[40];&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;cout&amp;lt;&amp;lt;&quot;Enter The Name &quot;&amp;lt;&amp;lt;endl;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;gets(arr);&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;cout&amp;lt;&amp;lt;arr[0]&amp;lt;&amp;lt;&quot;.&quot;;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;for(int i=0;arr[i]!=&#39;\0&#39;;i++)&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;{&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;  if(arr[i]==&#39; &#39;)&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;  {&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;  cout&amp;lt;&amp;lt;arr[i+1]&amp;lt;&amp;lt;&quot;.&quot;;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;  i++;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;  }&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;}&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;if(arr[i]==&#39;\0&#39;)&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;{&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;for(;arr[i]!=&#39; &#39;;i--);&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;  cout&amp;lt;&amp;lt;&quot;\b\b&quot;;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;  i++;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;  for(;arr[i]!=&#39;\0&#39;;i++)&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;  {cout&amp;lt;&amp;lt;arr[i];}&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;}&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;getch();&amp;nbsp;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;}&lt;/span&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;/pre&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;
&lt;h2 id=&quot;8034440_title&quot; style=&quot;background-color: white; color: #333333; font-weight: 400; font: normal normal bold 1.2em/normal Arial, Helvetica, sans-serif; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;Output&lt;/span&gt;&lt;/h2&gt;
&lt;div class=&quot;txtd&quot; id=&quot;txtd_8034440&quot; style=&quot;background-color: white; color: #333333; font-size: 14px; line-height: 18px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; word-wrap: break-word;&quot;&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;Enter The Name&lt;br style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot; /&gt;Mohandas Karamchand Gandhi&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: inherit;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;background-color: white; color: #333333; font-size: 14px; line-height: 18px;&quot;&gt;M.K.Gandhi&lt;/span&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/795135540165328047/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2010/10/c-program-to-accept-name-and-print.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/795135540165328047'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/795135540165328047'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2010/10/c-program-to-accept-name-and-print.html' title='C++ programming:program to accept your name and print initials:how to display initials:name initials sample in C'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-9187041306789926084</id><published>2010-10-30T22:18:00.000-07:00</published><updated>2022-06-15T01:12:46.501-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C functions"/><category scheme="http://www.blogger.com/atom/ns#" term="function arguments"/><category scheme="http://www.blogger.com/atom/ns#" term="function prototype"/><category scheme="http://www.blogger.com/atom/ns#" term="functions in c"/><category scheme="http://www.blogger.com/atom/ns#" term="how to use functions in C"/><category scheme="http://www.blogger.com/atom/ns#" term="return value in functions"/><category scheme="http://www.blogger.com/atom/ns#" term="use of functions in C++"/><title type='text'>how to use functions in C++: program using function to perform division,subtraction,multiply,sum of two numbers</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;iframe align=&quot;left&quot; frameborder=&quot;0&quot; marginheight=&quot;0&quot; marginwidth=&quot;0&quot; scrolling=&quot;no&quot; src=&quot;http://rcm.amazon.com/e/cm?t=cprogbydevs-20&amp;amp;o=1&amp;amp;p=8&amp;amp;l=bpl&amp;amp;asins=0201700735&amp;amp;fc1=000000&amp;amp;IS2=1&amp;amp;lt1=_blank&amp;amp;m=amazon&amp;amp;lc1=0000FF&amp;amp;bc1=000000&amp;amp;bg1=FFFFFF&amp;amp;f=ifr&quot; style=&quot;align: left; height: 245px; padding-right: 10px; padding-top: 5px; width: 131px;&quot;&gt;&lt;/iframe&gt;Functions implement modularity which in turn implements a well structured programming. Modularity ensures better control of the program. Modularity is close to the real world so every OOP has modularity in it.&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;Consider a scenario:&lt;/em&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;ul style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; margin-left: 2em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;1. A manager in a mobile store alone manages all the operations i.e. marketing, inventory control, stock, accounting etc. The manager finds himself struggling with the store operations. The store has a bad reputation. The business is suffering&lt;/li&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;2. A manager in a mobile store has individual supervisors for each operation i.e. marketing, inventory control, stock, accounting etc. The manager controls only the supervisors and the supervisors in turn control the operations. The mobile store is running smooth. The store has a good reputation. The business is flourishing&lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
It is clear from above scenarios that a well structured organization runs smooth. In the same way a well structured program runs smooth and ensures efficiency.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
If you are developing a calculator program. Rather than doing all the operations i.e. addition, subtraction, multiplication, division etc. in main() function only, make separate functions for each operation. It will have the benefits like:&lt;/div&gt;
&lt;ul style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; margin-left: 2em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;1. Program has modularity&lt;/li&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;2. If a particular operation is wrong, you have to debug that function only.&lt;/li&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;3. It is easy to understand the functions.&lt;/li&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;4. Control is better&lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;u style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;How to use functions in C++&lt;/u&gt;&lt;/em&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
Before making a function the following things should be decided&lt;/div&gt;
&lt;ul style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; margin-left: 2em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;1. Does the function return any value or return nothing means void&lt;/li&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;2. Does the function have any arguments or parameters&lt;/li&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;3. Meaningful name of the function&lt;/li&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;4. The working of the function&lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
A typical function to return the sum of two integer numbers can be like this:&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
int add(int,int);&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
The picture will be clearer by the programs in this tutorial.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
Now remember these points that a function appears 3 times in a program. For example&lt;/div&gt;
&lt;ul style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; margin-left: 2em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;1.&amp;nbsp;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;Function Prototype:&lt;/strong&gt;&amp;nbsp;A Function Prototype means an indication to compiler that a particular function will be used later in the program.&lt;/li&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;2.&amp;nbsp;&lt;/strong&gt;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;Function Call: A&amp;nbsp;&lt;/strong&gt;Function Call means to call a function to work&lt;/li&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;3.&amp;nbsp;&lt;/strong&gt;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;Function Definition: A&amp;nbsp;&lt;/strong&gt;Function Definition means the actual working of the function&lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
There can be the following categories of the functions:&lt;/div&gt;
&lt;ul style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; margin-left: 2em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;1. Function without arguments and without return value&lt;/li&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;2. Function with arguments and without return value&lt;/li&gt;
&lt;li style=&quot;margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;3. Function with arguments and with return value&lt;/li&gt;
&lt;/ul&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
These things will be clearer by the programs in this tutorial.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
Look at the following programs:&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;/div&gt;
&lt;h2 id=&quot;8110777_title&quot; style=&quot;font-weight: 400; font: normal normal bold 1.2em/normal Arial, Helvetica, sans-serif; line-height: normal; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
A program to show Functions without arguments and without return value&lt;/h2&gt;
&lt;pre class=&quot;moduleCode cpp&quot; id=&quot;code_d_8110777&quot; name=&quot;code&quot; style=&quot;font: normal normal normal 0.9em/normal &#39;Courier New&#39;, Courier, monospace; line-height: 1em; overflow-x: hidden; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; white-space: pre-wrap; width: 506px; word-wrap: break-word;&quot;&gt;/* the following program has 4 functions with no arguments and no return type*/
  
#include&amp;lt;iostream.h&amp;gt;
#include&amp;lt;conio.h&amp;gt;
void add();  //function prototype of add() 
void subtract(); //function prototype of subtract()
void multiply(); //function prototype of multiply()
void division(); //function prototype of division()
void main()
{
clrscr();
int choice;
char ans;
cout&amp;lt;&amp;lt;&quot;\nWant to see Menu Y or y for yes\n&quot;;
cin&amp;gt;&amp;gt;ans;
while(ans==&#39;y&#39;||ans==&#39;Y&#39;)
{
cout&amp;lt;&amp;lt;&quot;\nMENU\n&quot;;
cout&amp;lt;&amp;lt;&quot;1. Add\n&quot;;
cout&amp;lt;&amp;lt;&quot;2. Subtract\n&quot;;
cout&amp;lt;&amp;lt;&quot;3. Multiply\n&quot;;
cout&amp;lt;&amp;lt;&quot;4. Division\n&quot;;
cout&amp;lt;&amp;lt;&quot;\Enter the Choice 1-4\n&quot;;
cin&amp;gt;&amp;gt;choice;
switch(choice)
{ case 1: add(); //function call to add()
   break;
  case 2: subtract(); //function call to subtract()
   break;
  case 3: multiply(); //function call to multiply()
   break;
  case 4: division(); //function call to division()
   break;
  default:cout&amp;lt;&amp;lt;&quot;\nSorry Wrong Choice Try Again\n&quot;;
}
cout&amp;lt;&amp;lt;&quot;\nWant to see Menu Y or y for yes\n&quot;;
cin&amp;gt;&amp;gt;ans;
}
getch();
}
void add()  //function definition of add()
{
int a,b;
cout&amp;lt;&amp;lt;&quot;\nEnter two numbers a and b\n&quot;;
cin&amp;gt;&amp;gt;a&amp;gt;&amp;gt;b;
cout&amp;lt;&amp;lt;&quot;Sum of the numbers a and b is&quot;&amp;lt;&amp;lt;a+b;
}
void subtract()  //function definition of subtract()
{
int a,b;
cout&amp;lt;&amp;lt;&quot;\nEnter two numbers a and b\n&quot;;
cin&amp;gt;&amp;gt;a&amp;gt;&amp;gt;b;
cout&amp;lt;&amp;lt;&quot;a-b is&quot;&amp;lt;&amp;lt;a-b;
}
void multiply()  //function definition of multiply()
{
int a,b;
cout&amp;lt;&amp;lt;&quot;\nEnter two numbers a and b\n&quot;;
cin&amp;gt;&amp;gt;a&amp;gt;&amp;gt;b;
cout&amp;lt;&amp;lt;&quot;Product of the numbers a and b is&quot;&amp;lt;&amp;lt;a*b;
}
void division()  //function definition of division()
{
int a,b;
cout&amp;lt;&amp;lt;&quot;\nEnter two numbers a and b\n&quot;;
cin&amp;gt;&amp;gt;a&amp;gt;&amp;gt;b;
cout&amp;lt;&amp;lt;&quot;a/b is&quot;&amp;lt;&amp;lt;a/b;
}
&lt;/pre&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;h2 id=&quot;8111113_title&quot; style=&quot;font-weight: 400; font: normal normal bold 1.2em/normal Arial, Helvetica, sans-serif; line-height: normal; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
A program to show Functions with arguments and without return value&lt;/h2&gt;
&lt;pre class=&quot;moduleCode cpp&quot; id=&quot;code_d_8111113&quot; name=&quot;code&quot; style=&quot;font: normal normal normal 0.9em/normal &#39;Courier New&#39;, Courier, monospace; line-height: 1em; overflow-x: hidden; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; white-space: pre-wrap; width: 506px; word-wrap: break-word;&quot;&gt;/* the following program has 4 functions with arguments and no return type*/
  
#include&amp;lt;iostream.h&amp;gt;
#include&amp;lt;conio.h&amp;gt;
void add(int,int);
void subtract(int,int);
void multiply(int,int);
void division(int,int);
void main()
{
clrscr();

int choice;
char ans;
cout&amp;lt;&amp;lt;&quot;\nWant to see Menu Y or y for yes\n&quot;;
cin&amp;gt;&amp;gt;ans;
while(ans==&#39;y&#39;||ans==&#39;Y&#39;)
{
int a,b;
cout&amp;lt;&amp;lt;&quot;\nEnter two numbers a and b\n&quot;;
cin&amp;gt;&amp;gt;a&amp;gt;&amp;gt;b;
cout&amp;lt;&amp;lt;&quot;\nMENU\n&quot;;
cout&amp;lt;&amp;lt;&quot;1. Add\n&quot;;
cout&amp;lt;&amp;lt;&quot;2. Subtract\n&quot;;
cout&amp;lt;&amp;lt;&quot;3. Multiply\n&quot;;
cout&amp;lt;&amp;lt;&quot;4. Division\n&quot;;
cout&amp;lt;&amp;lt;&quot;\Enter the Choice 1-4\n&quot;;
cin&amp;gt;&amp;gt;choice;
switch(choice)
{ case 1: add(a,b);
   break;
  case 2: subtract(a,b);
   break;
  case 3: multiply(a,b);
   break;
  case 4: division(a,b);
   break;
  default:cout&amp;lt;&amp;lt;&quot;\nSorry Wrong Choice Try Again\n&quot;;
}
cout&amp;lt;&amp;lt;&quot;\nWant to see Menu Y or y for yes\n&quot;;
cin&amp;gt;&amp;gt;ans;
}
getch();
}
void add(int a,int b)
{
cout&amp;lt;&amp;lt;&quot;Sum of the numbers a and b is: &quot;&amp;lt;&amp;lt;a+b;
}
void subtract(int a,int b)
{
cout&amp;lt;&amp;lt;&quot;a-b is: &quot;&amp;lt;&amp;lt;a-b;
}
void multiply(int a,int b)
{
cout&amp;lt;&amp;lt;&quot;Product of the numbers a and b is: &quot;&amp;lt;&amp;lt;a*b;
}
void division(int a,int b)
{
cout&amp;lt;&amp;lt;&quot;a/b is: &quot;&amp;lt;&amp;lt;a/b;
}
&lt;/pre&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;h2 id=&quot;8111114_title&quot; style=&quot;font-weight: 400; font: normal normal bold 1.2em/normal Arial, Helvetica, sans-serif; line-height: normal; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
A program to show Functions with arguments and with return value&lt;/h2&gt;
&lt;pre class=&quot;moduleCode cpp&quot; id=&quot;code_d_8111114&quot; name=&quot;code&quot; style=&quot;font: normal normal normal 0.9em/normal &#39;Courier New&#39;, Courier, monospace; line-height: 1em; overflow-x: hidden; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; white-space: pre-wrap; width: 506px; word-wrap: break-word;&quot;&gt;/* the following program has 4 functions with arguments and return type */ 
#include&amp;lt;iostream.h&amp;gt;
#include&amp;lt;conio.h&amp;gt;
int add(int,int);
int subtract(int,int);
int multiply(int,int);
int division(int,int);
void main()
{
clrscr();
int choice;
char ans;
cout&amp;lt;&amp;lt;&quot;\nWant to see Menu Y or y for yes\n&quot;;
cin&amp;gt;&amp;gt;ans;
while(ans==&#39;y&#39;||ans==&#39;Y&#39;)
{
int a,b,c;
cout&amp;lt;&amp;lt;&quot;\nEnter two numbers a and b\n&quot;;
cin&amp;gt;&amp;gt;a&amp;gt;&amp;gt;b;
cout&amp;lt;&amp;lt;&quot;\nMENU\n&quot;;
cout&amp;lt;&amp;lt;&quot;1. Add\n&quot;;
cout&amp;lt;&amp;lt;&quot;2. Subtract\n&quot;;
cout&amp;lt;&amp;lt;&quot;3. Multiply\n&quot;;
cout&amp;lt;&amp;lt;&quot;4. Division\n&quot;;
cout&amp;lt;&amp;lt;&quot;\Enter the Choice 1-4\n&quot;;
cin&amp;gt;&amp;gt;choice;
switch(choice)
{ case 1: c=add(a,b);
   cout&amp;lt;&amp;lt;&quot;Sum of the numbers a and b is: &quot;&amp;lt;&amp;lt;c;
   break;
  case 2: c=subtract(a,b);
   cout&amp;lt;&amp;lt;&quot;a-b is: &quot;&amp;lt;&amp;lt;c;
   break;
  case 3: c=multiply(a,b);
   cout&amp;lt;&amp;lt;&quot;Product of the numbers a and b is: &quot;&amp;lt;&amp;lt;c;
   break;
  case 4: c=division(a,b);
   cout&amp;lt;&amp;lt;&quot;a/b is: &quot;&amp;lt;&amp;lt;c;
   break;
  default:cout&amp;lt;&amp;lt;&quot;\nSorry Wrong Choice Try Again\n&quot;;
}
cout&amp;lt;&amp;lt;&quot;\nWant to see Menu Y or y for yes\n&quot;;
cin&amp;gt;&amp;gt;ans;
}
getch();
}
int add(int a,int b)
{
return a+b;
}
int subtract(int a,int b)
{
return a-b;
}
int multiply(int a,int b)
{
return a*b;
}
int division(int a,int b)
{
return a/b;
}&lt;/pre&gt;
&lt;pre class=&quot;moduleCode cpp&quot; id=&quot;code_d_8111114&quot; name=&quot;code&quot; style=&quot;font: normal normal normal 0.9em/normal &#39;Courier New&#39;, Courier, monospace; line-height: 1em; overflow-x: hidden; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; white-space: pre-wrap; width: 506px; word-wrap: break-word;&quot;&gt;
&lt;/pre&gt;
&lt;pre class=&quot;moduleCode cpp&quot; id=&quot;code_d_8111114&quot; name=&quot;code&quot; style=&quot;font: normal normal normal 0.9em/normal &#39;Courier New&#39;, Courier, monospace; line-height: 1em; overflow-x: hidden; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; white-space: pre-wrap; width: 506px; word-wrap: break-word;&quot;&gt;&lt;div style=&quot;font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; white-space: normal;&quot;&gt;
If anyone wants more clarification, he or she can post comments in this article. I will clarify the doubts.&lt;/div&gt;
&lt;div style=&quot;font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; white-space: normal;&quot;&gt;
Thanks for reading this article.&amp;nbsp;&lt;/div&gt;
&lt;/pre&gt;
&lt;/div&gt;
&lt;br /&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/9187041306789926084/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2010/10/functions-in-c.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/9187041306789926084'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/9187041306789926084'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2010/10/functions-in-c.html' title='how to use functions in C++: program using function to perform division,subtraction,multiply,sum of two numbers'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-7749862214970435933</id><published>2010-10-30T22:13:00.000-07:00</published><updated>2022-06-15T01:12:46.465-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="array basics in C programming language"/><category scheme="http://www.blogger.com/atom/ns#" term="arrays in C++"/><category scheme="http://www.blogger.com/atom/ns#" term="arrays tutorials in C"/><category scheme="http://www.blogger.com/atom/ns#" term="character arrays in c"/><category scheme="http://www.blogger.com/atom/ns#" term="how to use arrays in c programming"/><title type='text'>Arrays in C++ programming:program that will store numbers or values in array? turbo c program how to accept 10 integer</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;iframe align=&quot;left&quot; frameborder=&quot;0&quot; marginheight=&quot;0&quot; marginwidth=&quot;0&quot; scrolling=&quot;no&quot; src=&quot;http://rcm.amazon.com/e/cm?t=cprogbydevs-20&amp;amp;o=1&amp;amp;p=8&amp;amp;l=bpl&amp;amp;asins=0201721481&amp;amp;fc1=000000&amp;amp;IS2=1&amp;amp;lt1=_blank&amp;amp;m=amazon&amp;amp;lc1=0000FF&amp;amp;bc1=000000&amp;amp;bg1=FFFFFF&amp;amp;f=ifr&quot; style=&quot;align: left; height: 245px; padding-right: 10px; padding-top: 5px; width: 131px;&quot;&gt;&lt;/iframe&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;u style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;Array Basics in C++ programming language:&lt;/strong&gt;&lt;/em&gt;&lt;/u&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
Arrays are extremely important for every computer programming language including C++. There are situations when we need arrays in every programming language. In this chapter I will explain the basics of arrays in C++ programming language.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;u style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;When we need an array?&lt;/strong&gt;&lt;/em&gt;&lt;/u&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
When many variables are required of same data type and they all need to be treated the same way. For example: To store the first 10 even numbers we can declare an array of size 10.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;u style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;Why we need array?&lt;/strong&gt;&lt;/em&gt;&lt;/u&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
In the above example: rather than declaring 10 different integers, we can declare an array with no headache of memorizing 10 different variable names.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;u style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;What is an array?&lt;/strong&gt;&lt;/em&gt;&lt;/u&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
Array is a collection of variables of same data type under a single name.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;u style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;How we use array?&lt;/strong&gt;&lt;/em&gt;&lt;/u&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
There are different kinds of arrays: 1D, 2 D, 3D [D=Dimensions] for each data type. But here I am going to explain 1D array for integer or float data type. Char data type arrays have a different approach. I will explain them in the different chapters.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
For example: if we need to store the first 10 even numbers, we can declare an array of integers like this:&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhaxb0AqdTYJXwLZ81Qu2r0LNQwyvJoxHYodqoFY472l85kv4PpTKz1VB865Puw-w7zSV_U6Nb-ML4BSneecMMpHWs_-9p4Tlf0veFPGSY8tlpuHMjh5YkA_NvJ99VJJiowVj0p5VZBABU/s1600/array.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;258&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhaxb0AqdTYJXwLZ81Qu2r0LNQwyvJoxHYodqoFY472l85kv4PpTKz1VB865Puw-w7zSV_U6Nb-ML4BSneecMMpHWs_-9p4Tlf0veFPGSY8tlpuHMjh5YkA_NvJ99VJJiowVj0p5VZBABU/s400/array.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
rather than creating 10 variables like int a,b,c,d,e,f,g,h,I,j;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
In memory 10 integers are declared in sequential memory locations:&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
In an array subscript or index always starts with ZERO. The subscripts are used by the compiler to locate the array item. For example to refer to the values 2,4,6,…,20 the&amp;nbsp;compiler&amp;nbsp;refers them in this way:&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
arr[0], arr[1], arr[2],… arr[9]&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
Try this code in C++ compiler.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
//Program to store first 10 even numbers and print them&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
#include&amp;lt;iostream.h&amp;gt;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
void main()&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
{&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
int arr[10], i,val;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
/* In the following loop i is used to run the loop 10 times. i is initialized with ZERO because subscript starts with ZERO. val is used to store values starting from 2 and incrementing by 2 each time.*/&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
for(i=0,val=2; i&amp;lt;=9;i++,val=val+2)&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
arr[i]=val;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
for (i=0;i&amp;lt;=9;i++)&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
cout&amp;lt;&amp;lt;arr[i]&amp;lt;&amp;lt;endl;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
}&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
The Output of this&amp;nbsp;program&amp;nbsp;is:&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
2&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
4&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
6&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
8&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
10&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
12&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
14&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
16&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
18&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
20&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
The above C++ program is run in turbo c compiler.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
The integer and float arrays have the same concept. The only difference is of their data types. integers store whole numbers while floats store decimal numbers.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
Character arrays have a different concept which I have explained in this article:&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/7749862214970435933/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2010/10/array-basics-in-c-programming-language.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/7749862214970435933'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/7749862214970435933'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2010/10/array-basics-in-c-programming-language.html' title='Arrays in C++ programming:program that will store numbers or values in array? turbo c program how to accept 10 integer'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhaxb0AqdTYJXwLZ81Qu2r0LNQwyvJoxHYodqoFY472l85kv4PpTKz1VB865Puw-w7zSV_U6Nb-ML4BSneecMMpHWs_-9p4Tlf0veFPGSY8tlpuHMjh5YkA_NvJ99VJJiowVj0p5VZBABU/s72-c/array.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7629947319940983854.post-4193043744960029899</id><published>2010-10-30T22:08:00.000-07:00</published><updated>2022-06-15T01:12:46.429-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="character arrays in c"/><category scheme="http://www.blogger.com/atom/ns#" term="character count program in c"/><category scheme="http://www.blogger.com/atom/ns#" term="data structures in c"/><category scheme="http://www.blogger.com/atom/ns#" term="palindrome string program in c"/><category scheme="http://www.blogger.com/atom/ns#" term="string reverse program in C++"/><title type='text'>character or char arrays as data structures in c: string reverse program and palindrome program using c programming</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial, Helvetica, sans-serif; font-size: 19px; font-weight: bold;&quot;&gt;c programming arrays ---&amp;gt; data structures in c: char arrays in c programming&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;txtd&quot; id=&quot;txtd_8025023&quot; style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; word-wrap: break-word;&quot;&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;C&amp;nbsp;programming arrays:&lt;/strong&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
Arrays are important&amp;nbsp;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;data structures in C&lt;/strong&gt;.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
Arrays are very much useful in situations when we need to store many variables of same data type and treat them similarly. For understanding c programming arrays and arrays as data structures in c, read the hub “Array Basics in C programming”&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
I am explaining here only character arrays in c programming.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
What is an array?&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
An array is collection of similar type of data items.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
And a character array is called a string.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
Character arrays in C programming have a different concept from integer arrays or float arrays in C. Character arrays are declared in the same way as integer or float arrays but one thing that is different in character arrays is that a&amp;nbsp;NULL character&amp;nbsp;(‘\0’) is appended automatically at the end of the character array.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
char arr[10];&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
the above statement declares a character array named arr with 10 continuous memory locations each occupying&amp;nbsp;1 byte&amp;nbsp;because the base size of a character data type is 1 Byte. So the above array takes 10 Bytes in memory.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
Now a string (group of character or a character array is called a string) is input in array by the&amp;nbsp;following statement.&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
cin&amp;gt;&amp;gt;arr;&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
In the above input statement the string does not contain any whitespace because cin&amp;gt;&amp;gt; ends the string where a whitespace is encountered. If whitespaces are to be&amp;nbsp;input&amp;nbsp;then the following statement can be used&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
gets(arr);&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
do not forget to include stdio.h file to let the gets() function work&lt;/div&gt;
&lt;div style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
Suppose if the user inputs “HELLO” from the keyboard. The actual storage in&amp;nbsp;memory&amp;nbsp;would be :&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8-bvY75sRJaR9VXc-7WbNpHtTNx9JzWNFACo1G1uwpvRUCtpr0tKaHriyky8ehbPbmhfN4Azi50yWG0TVu7AewOm1jrhRzzSz7ZrQ9306GirrJUc98fpRx6rQ2XRxH-PB9JxDfzcOYrE/s1600/char+array.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8-bvY75sRJaR9VXc-7WbNpHtTNx9JzWNFACo1G1uwpvRUCtpr0tKaHriyky8ehbPbmhfN4Azi50yWG0TVu7AewOm1jrhRzzSz7ZrQ9306GirrJUc98fpRx6rQ2XRxH-PB9JxDfzcOYrE/s1600/char+array.jpg&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;/div&gt;
&lt;h2 id=&quot;8025231_title&quot; style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-weight: 400; font: normal normal bold 1.2em/normal Arial, Helvetica, sans-serif; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;

c programming arrays: arrays as data structures in c : sample programs&lt;/h2&gt;
&lt;div class=&quot;txtd&quot; id=&quot;txtd_8025231&quot; style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; word-wrap: break-word;&quot;&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
A NULL Character(‘\0’) or string terminator is automatically appended after the last character of the string. It (‘\0’) marks the end of the string. This does not happen in integer or float&amp;nbsp;arrays in C++.&lt;/div&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;u style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;Example 1:&lt;/strong&gt;&lt;/em&gt;&lt;/u&gt;&lt;/div&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;span style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;/strong&gt;&lt;/em&gt;&lt;/span&gt;&lt;/div&gt;
&lt;h2 id=&quot;9364162_title&quot; style=&quot;font-style: normal; font-weight: 400; font: normal normal bold 1.2em/normal Arial, Helvetica, sans-serif; line-height: normal; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: underline;&quot;&gt;

&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;c programming arrays: char arrays as data structures in c: sample program to reverse a string and count number of characters in string&lt;/strong&gt;&lt;/em&gt;&lt;/h2&gt;
&lt;pre class=&quot;moduleCode cpp&quot; id=&quot;code_d_9364162&quot; name=&quot;code&quot; style=&quot;font: normal normal normal 0.9em/normal &#39;Courier New&#39;, Courier, monospace; line-height: 1em; overflow-x: hidden; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; white-space: pre-wrap; width: 506px; word-wrap: break-word;&quot;&gt;&lt;span style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;span style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;/* program to input a string then count number of characters in string and

print the reverse of the string*/

#include&amp;lt;stdio.h&amp;gt; //for printf , scanf and other functions

#include&amp;lt;conio.h&amp;gt; //for clrscr() and getch()functions

void main()

{

clrscr();

char arr[10];

printf(&quot;Enter A String\n&quot;);

gets(arr);

for(int i=0;arr[i]!=&#39;\0&#39;;i++);//empty loop which does not have a body

printf(&quot;Length of the string is %d&quot;, i);

//now reverse print of the string

for(i--;i&amp;gt;=0;i--)

printf(&quot;%c&quot;,arr[i]);

getch();

}&lt;/span&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;
&lt;br /&gt;
&lt;div&gt;
&lt;h2 id=&quot;9364205_title&quot; style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-weight: 400; font: normal normal bold 1.2em/normal Arial, Helvetica, sans-serif; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;

c programming arrays: char arrays as data structures in c: sample program 1 output&lt;/h2&gt;
&lt;div class=&quot;txtd&quot; id=&quot;txtd_9364205&quot; style=&quot;background-color: white; color: #333333; font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; word-wrap: break-word;&quot;&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
OUTPUT:&lt;/div&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
Enter A String&lt;/div&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
MADAM&lt;/div&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
String is palindrome&lt;/div&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;u style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;Example 2:&lt;/u&gt;&lt;/em&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;span style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;/span&gt;&lt;/em&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;h2 id=&quot;9364243_title&quot; style=&quot;font-style: normal; font-weight: 400; font: normal normal bold 1.2em/normal Arial, Helvetica, sans-serif; line-height: normal; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: underline;&quot;&gt;

&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;c programming arrays: char arrays as data structures in c: sample program to check a string is palindrome or not&lt;/em&gt;&lt;/strong&gt;&lt;/h2&gt;
&lt;pre class=&quot;moduleCode cpp&quot; id=&quot;code_d_9364243&quot; name=&quot;code&quot; style=&quot;font: normal normal normal 0.9em/normal &#39;Courier New&#39;, Courier, monospace; line-height: 1em; overflow-x: hidden; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; white-space: pre-wrap; width: 506px; word-wrap: break-word;&quot;&gt;&lt;span style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;span style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;/*Program to input a string then check whether string is palindrome or not
A palindrome string is same as its reverse like RADAR, NITIN, MADAM */

#include&amp;lt;stdio.h&amp;gt;  //for printf, scanf,gets  and other functions
#include&amp;lt;conio.h&amp;gt;  //for clrscr() and getch()functions
void main()
{
clrscr();

char arr[10];
int i,j,flag=1;
printf(&quot;\n Enter A String\n&quot;);

gets(arr);

for(i=0;arr[i]!=&#39;\0&#39;;i++);//empty loop which does not have a body
for(j=0,i--;i&amp;gt;=0;i--,j++)//i moves backward and j moves forward
{
 if(arr[i]!=arr[j])
 {
  flag=0;
  break;
 }
}
if(flag==1)
printf(&quot;String is palindrome&quot;);
else
printf(&quot;String is not palindrome&quot;);

getch();
}&lt;/span&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class=&quot;moduleCode cpp&quot; id=&quot;code_d_9364243&quot; name=&quot;code&quot; style=&quot;font-style: normal; font-weight: normal; font: normal normal normal 0.9em/normal &#39;Courier New&#39;, Courier, monospace; line-height: 1em; overflow-x: hidden; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; white-space: pre-wrap; width: 506px; word-wrap: break-word;&quot;&gt;&lt;h2 id=&quot;9364252_title&quot; style=&quot;font-family: Arial, Helvetica, sans-serif; font-weight: 400; font: normal normal bold 1.2em/normal Arial, Helvetica, sans-serif; line-height: normal; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; white-space: normal;&quot;&gt;

&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;c programming arrays: char arrays as data structures in c: sample program 2 output&lt;/em&gt;&lt;/strong&gt;&lt;/h2&gt;
&lt;div class=&quot;txtd&quot; id=&quot;txtd_9364252&quot; style=&quot;font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 18px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; white-space: normal; word-wrap: break-word;&quot;&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;OUTPUT:&lt;/em&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;Enter A String&lt;/em&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;MADAM&lt;/em&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;String is palindrome&lt;/em&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;div style=&quot;margin-bottom: 0.75em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;strong style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;&lt;em style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;&quot;&gt;
&lt;/em&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://thecplusplus.blogspot.com/feeds/4193043744960029899/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://thecplusplus.blogspot.com/2010/10/character-or-char-arrays-as-data.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/4193043744960029899'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7629947319940983854/posts/default/4193043744960029899'/><link rel='alternate' type='text/html' href='http://thecplusplus.blogspot.com/2010/10/character-or-char-arrays-as-data.html' title='character or char arrays as data structures in c: string reverse program and palindrome program using c programming'/><author><name>Devendra Singh Yadav</name><uri>http://www.blogger.com/profile/07773563122865705642</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4i2GXhluRPmteDOlNQVqd0EAOI4DGVZ0tw6LO0lMYm8KhvxQdKKu7tv5YCinl9RpDtfwmQcBmmtFdWz7JN2Uof5lzzGvMIEne4RQoyWYEFoP1dHvdp-IcMp77mcumUA/s113/Devendra.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8-bvY75sRJaR9VXc-7WbNpHtTNx9JzWNFACo1G1uwpvRUCtpr0tKaHriyky8ehbPbmhfN4Azi50yWG0TVu7AewOm1jrhRzzSz7ZrQ9306GirrJUc98fpRx6rQ2XRxH-PB9JxDfzcOYrE/s72-c/char+array.jpg" height="72" width="72"/><thr:total>0</thr:total></entry></feed>