Answers for "get element from array c++"

C++
1

get an array with c++

int arr[5];
for(int i=0;i<5;i++)
{
  cin>>arr[i];
}
Posted by: Guest on May-31-2021
1

how to get an element in a list c++

#include <list>

auto it = yourList.begin();
std::advance(it, index);

std::cout << *it;
Posted by: Guest on November-06-2020

Code answers related to "get element from array c++"

Browse Popular Code Answers by Language