chillurbrain

Task9_7_1

Dec 22nd, 2015
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.34 KB | None | 0 0
  1. #include "stdafx.h"
  2. #include <iostream>
  3. #include <conio.h>
  4.  
  5. using namespace std;
  6.  
  7. int main()
  8. {
  9.     const int SIZE = 3;
  10.     int arr[SIZE];
  11.     int* ptr[SIZE];
  12.     for(int i = 0; i < SIZE; i++)
  13.         ptr[i] = &arr[i];
  14.     for(int i = 0; i < SIZE; i++)
  15.         cin >> arr[i];
  16.     for(int i = 0; i < SIZE; i++)
  17.         cout << *ptr[i] << " ";
  18.     _getch();
  19.     r
Add Comment
Please, Sign In to add comment