Wap in c to Print integer value using while loop Programming

Print integer value using while loop

Before Executing this program, First, try to understand, Print integer value using while loop, we know why to use While loop() because while guarantees block will execute at least once. we try to understand this Program or Read here isalpha() function.

Thank you for reading this post, don't forget to subscribe!

Program using while loop in C

#include <stdio.h>
void copy_string(char*,char*);
int main() {
char source[100],target[100];
puts("enter source string:\n");
gets(source);
copy_string(target,source);
printf("target string is\"%s\"\n",target);
return 0;
}
void copy_string(char *target,char *source){
while(*source)
{
*target=*source;
source++;
target++;
}
*target='\0';
}

Example of while loop Output

Enter source string: 2 3

target string is”2 3″

While loop in C

Print integer value using while loop
Print integer value using while loop

 C Programming using while loop

END

Saurabh Nissa

This is SaurabhNissa, Owner of Thesmolt.com I'm Graduated from Magadh University in 2019 with 75%. Currently, I'm working on my Personal educational website for teaching Programming language free of Coast, and want to provide a Full setup for Specially BCA student