fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int i,p[]={1,2,3,4};
  6. int* q = p;
  7. for(i=0;i<4;i++)
  8. {
  9. cout<<*q;
  10. q++;
  11. }
  12. }
Success #stdin #stdout 0s 3296KB
stdin
Standard input is empty
stdout
1234