How to guarantee a 64‑bit integer across platforms in Rust

1 Answer

0 votes
fn main() {
    let x: i64 = -123_456_789_012_345;
    let y: u64 = 123_456_789_012_345;

    println!("x = {}", x);
    println!("y = {}", y);
}

  
   
/*
run:
   
x = -123456789012345
y = 123456789012345
  
*/

 



answered Feb 23 by avibootz
...