2d Vector Rust

[Solved] 2d Vector Rust | Rust - Code Explorer | yomemimo.com
Question : 2d vector rust

Answered by : shane-whitmire

fn test(vec: &mut Vec<Vec<char>>){ vec[0][0] = 'd'; ..// vec[23][79] = 'd';
}
fn main() { let mut vec = vec![vec!['#'; 80]; 24]; test(&mut vec);
}

Source : https://stackoverflow.com/questions/13102786/two-dimensional-vectors-in-rust | Last Update : Sun, 13 Mar 22

Answers related to 2d vector rust

Code Explorer Popular Question For Rust