Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- fn main() {
- let num = match "12345".parse::<u32>() {
- Ok(n) => n,
- Err(_) => panic!("Unable to parse integer"),
- };
- assert_eq!(num, 12345);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement