# Enter Range of numbers and replaced them in C, CPP, Cplusplus

## Enter Range of numbers and replaced them in C, CPP, Cplusplus

In this tutorial, we will answer the followings;

1. Draw a flowchart of a program to enter the range of numbers and replaced them with C, CPP, Cplusplus
2. Write a programme to enter the range of numbers and replaced them in CPP, Cplusplus
3. Write a programme to enter the range of numbers and replaced them in C

Draw a flowchart of a program to enter the range of numbers and replaced them with C, CPP, Cplusplus

Write a programme to enter the range of numbers and replaced them in CPP, Cplusplus

```//zz zoo Program in C
//Write a program in C/c++ which prints the numbers from 1 to 100. But,
//multiples of 3 should be replaced with "Zoo",
//multiples of 5 should be replaced with "Zz"
// and multiples of both 3 and 5 should be replaced with "ZzZoo"?.
#include<iostream>
#include<conio.h>
using namespace std;
int main()
{
int num_list;
int loop;

cout<<"Please Enter the range of numbers : ";
cin >>num_list;
for(loop=1; loop<=num_list; loop++)
{
if((loop % (3*5)) == 0)
{
cout<<"\n ZzZoo";
}
else if ((loop % 5) == 0)
{
cout<<"\n Zz";
}
else if ((loop % 3) == 0)
{
cout<<"\n Zoo";
}
else
{
cout<<"\n"<<loop;
}
}
getch();
}
```

Output

Write a programme to enter the range of numbers and replaced them in C

```//zz zoo Program in C
//Write a program in C/c++ which prints the numbers from 1 to 100. But,
//multiples of 3 should be replaced with "Zoo",
//multiples of 5 should be replaced with "Zz"
// and multiples of both 3 and 5 should be replaced with "ZzZoo"?.
#include<stdio.h>
#include<conio.h>
int main()
{
int num_list;
int loop;

printf("Please Enter the range of numbers : ");
scanf("%d",&num_list);
for(loop=1; loop<=num_list; loop++)
{
if((loop % (3*5)) == 0)
{
printf("ZzZoo\n");
}
else if ((loop % 5) == 0)
{
printf("Zz\n");
}
else if ((loop % 3) == 0)
{
printf("Zoo\n");
}
else
{
printf("%d \n",loop);
}
}
getch();
}```

Output