rabbinur

To input on console screen by making two dimensional array

Sep 14th, 2012
42
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.27 KB | None | 0 0
  1. #include<iostream.h>
  2. #include<conio.h>
  3. #define a 3
  4. #define b 3
  5.  void main()
  6.   {
  7.  
  8.    int x[a][b];
  9.  
  10.    clrscr();
  11.  
  12.    for(int i=0; i<a; i++)
  13.    for(int j=0; j<b; j++)
  14.     {
  15.      cout<<"x["<<i<<"]["<<j<<"]=";
  16.      cin>>x[i][j];
  17.     }
  18.  
  19.      getch();
  20.    }
Advertisement
Add Comment
Please, Sign In to add comment