Horje
how to point to next array using pointer c++ Code Example
how to point to next array using pointer c++
#include <iostream>
using namespace std;
int main() {
   int arr[5] = {1, 2, 3, 4, 5};
   int *ptr = &arr[0];
   cout<<"The values in the array are: ";
   for(int i = 0; i < 5; i++) {
      cout<< *ptr <<" ";
      ptr++;
   }
   return 0;
}




Cpp

Related
dijkstra algorithm in c++ geeksforgeeks Code Example dijkstra algorithm in c++ geeksforgeeks Code Example
kadane algo Code Example kadane algo Code Example
? c++ Code Example ? c++ Code Example
why do men drink liquor Code Example why do men drink liquor Code Example
c++ generic pointer Code Example c++ generic pointer Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
7