Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR RUST

rust how to create array with the same value

let a = [3; 5]; // array of 5 elements with each being a 3 literal
Source by doc.rust-lang.org #
 
PREVIOUS NEXT
Tagged: #rust #create #array
ADD COMMENT
Topic
Name
8+7 =