Answers for "rust how to access elements of an array"

0

rust how to access elements of an array

fn main() {
    let a = [1, 2, 3, 4, 5];

    let first = a[0];
    let second = a[1];
}
Posted by: Guest on January-05-2022

Code answers related to "rust how to access elements of an array"

Browse Popular Code Answers by Language