Skip to Main Content
Xpress Learning - Computer Fundamentals of Programming an IT by Pearson
book

Xpress Learning - Computer Fundamentals of Programming an IT by Pearson

by Ashok N. Kamthane, Rohit Khurana
May 2024
Beginner to intermediate content levelBeginner to intermediate
465 pages
16h 14m
English
Pearson India
Content preview from Xpress Learning - Computer Fundamentals of Programming an IT by Pearson
Loop Control Statements II-127
16. Program to display string.
void main()
{
int i=0;
char a[5]={'A','s','h','o','k'};
clrscr();
printf("\nTransmitted information is:-");
while(i<=4)
{
printf("%c",a[i]);
i++;
}
printf("\n Received information is:-");
i=0;
while (i<=4)
{
printf("%c",a[i]+3);
i++;
}
getche();
}
OUTPUT:
Transmitted information is:- A s h o k
Received information is:- D v k r n
17. Program to display factorial of 6.
void main()
{
int a=6,b=1,fact=1;
clrscr();
do
{
fact=fact*b;
b=b+1;
}
while(b<=a);
printf("%d",fact);
getche();
}
OUTPUT:
720
M06_ITL-ESL4791_02_SE_C06.indd 127 12/22/2012 5:02:23 PM
II-128 Programming Concepts
18. Program to input binary number and find its ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Express Learning - Computer Fundamentals and Programming

Express Learning - Computer Fundamentals and Programming

Ashok Kamthane, ITL ESL
Windows® Internals, Sixth Edition, Part 2

Windows® Internals, Sixth Edition, Part 2

David A. Solomon Mark E. Russinovich and Alex Ionescu

Publisher Resources

ISBN: 9781299954878