Search
 
SCRIPT & CODE EXAMPLE
 

CPP

print 2d vector c++

	for(int i=0; i<v.size(); i++) 
		for(int j=0; j<v[i].size(); j++) 
  			cout<<v[i][j]<<" ";
        cout<<endl;
Comment

2d vector print

for(auto lst : vec){
  for(auto e : lst){
  	cout<<e<<" ";
  }
  cout<<endl;
}	
Comment

print 2d array c++

for( auto &row : arr) {
    for(auto col : row)
         cout << col << " ";
	cout<<endl; 
}
Comment

PREVIOUS NEXT
Code Example
Cpp :: how to print a string to console in c++ 
Cpp :: underline in latex 
Cpp :: flutter datetime format 
Cpp :: c++ message box error 
Cpp :: shuffle vector c++ 
Cpp :: iterator on std::tuple 
Cpp :: convert whole string to lowercase c++ 
Cpp :: how to check string contains char in c++ 
Cpp :: calculate time difference cpp 
Cpp :: unordered_map of pair and int 
Cpp :: string to size_t cpp 
Cpp :: c++ print hello world 
Cpp :: reverse sort cpp 
Cpp :: c++ write to file 
Cpp :: erosion and dilation c++ 
Cpp :: c++ fast 
Cpp :: insert at position in vector c++ 
Cpp :: time measurement c++ 
Cpp :: c++ string to wstring 
Cpp :: c++ default array value not null 
Cpp :: taking user input for a vector in c++ 
Cpp :: initialize all elements of vector to 0 c++ 
Cpp :: finding no of unique characters in a string c++ 
Cpp :: c++ split string by space into vector 
Cpp :: remove element from vector on condition c++ 
Cpp :: swap values in array c++ 
Cpp :: heap buffer overflow c++ 
Cpp :: capitalize first letter c++ 
Cpp :: how to convert int to string c++ 
Cpp :: cpp macro 
ADD CONTENT
Topic
Content
Source link
Name
8+4 =