Sort a vector of nums

    0

    0

    Giovanny Gongora

    Codiga's Rust Recipes

    vector of numbers

    fn main() {
      let mut vec = vec![1, 5, 10, 2, 15];
      vec.sort();
      assert_eq!(vec, vec![1, 2, 5, 10, 15]);
    }
    
    Codiga Logo
    Codiga Hub
    • Rulesets
    • Explore
    • Cookbooks
    • Playground
    soc-2 icon

    We are SOC-2 Compliance Certified

    G2 high performer medal

    Codiga – All rights reserved 2022.