/*1. Write a program that reads 15 double values from a user into an array and prints the floor of each*/
#include<iostream>
#include<iomanip>
using namespace std;
void main()
{
int counter=1;
double numbers[15]={0};
for(int i=0;i<15;i++)
{
cout<<"Please Enter Value "<<counter++<<" = ";
cin>>numbers[i];
}
system("cls");
for(int b=0;b<15;b++)
{
cout<<"The index "<<b<<" in the array = "<<numbers[b]<<endl;
}
system("pause");
}
Output :-
0 Questions:
Post a Comment