fn main() {
let v = vec![12; 4];
let v1 = vec![7; 5];
//1. In general, the {}
will be automatically replaced with any
// arguments in order of their placement. These will be stringified.
println!("{:?}", v);
println!("First vector: {0:?} and Second vector: {1:?} ", v, v1);
//Results above
//[12, 12, 12, 12]
//First vector: [12, 12, 12, 12] and Second vector: [7, 7, 7, 7, 7]
//2.With Positional arguments
println!("{0:?}", v);
println!("First vector: {0:?} and Second vector: {1:?} ", v, v1);
// Results above
//[12, 12, 12, 12]
//First vector: [12, 12, 12, 12] and Second vector: [7, 7, 7, 7, 7]
//2.You could assign variables for Positional arguments as well
println!("{var1:?}", var1 =v);
println!("First vector: {var1:?} and Second vector: {var2:?} ", var1=v, var2=v1);
// Results above
//[12, 12, 12, 12]
//First vector: [12, 12, 12, 12] and Second vector: [7, 7, 7, 7, 7]
}