Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CPP

initializing 2d vector

// to make (n rows x m columns) 2D array, all initialized 
// with value 'k' (typeof(k) = T)
vector<vector<T>> vec( n , vector<T> (m, k)); 
Source by www.techiedelight.com #
 
PREVIOUS NEXT
Tagged: #initializing #vector
ADD COMMENT
Topic
Name
5+9 =