Saturday, August 18, 2018

ARRAY: INPUT AND OUTPUT PROGRAM

#include<stdio.h>
#include<conio.h>
void main()
{
  int arr[10], i;               //array of size 10
  printf("Enter the array elements:");
 for(i=0;i<10;i++)    //inputting the value on array
{
  scanf("%d",&arr[i]);
}
printf("The values of array are:"); //displaying the value on console
 for(i=0;i<10;i++)
 {
   printf("%d,",arr[i]);
 }
 getch();

}

OUTPUT:


No comments:

Post a Comment

Static Member Function

CODE : #include<iostream> using namespace std; class test  {     int code;       static int count;               //static...