// Program to take 15 values from the user and store them in an array
#include <stdio.h>
#include<conio.h>
int main() {
int arr[15];
printf("Enter 15 integers: ");
for(int i = 0; i < 15; ++i) //Enter the 15 element in array
{
scanf("%d", &arr[i]);
}
printf("Displaying : ");
// printing elements of an array
for(int i = 0; i < 15; ++i) {
printf("%d\n", arr[i]);
}
getch();
return 0;
}
No comments:
Post a Comment