Skip to content

Instantly share code, notes, and snippets.

@dacr
Last active October 16, 2024 19:54
Show Gist options
  • Save dacr/bc5260541c9209b8a88de395bb8578a4 to your computer and use it in GitHub Desktop.
Save dacr/bc5260541c9209b8a88de395bb8578a4 to your computer and use it in GitHub Desktop.
hello rust loops / published by https://github.com/dacr/code-examples-manager #08b29534-8ae4-42f8-8ada-dd024d2e6e0f/b66d79c7111ea503d66817716f3d9df4c47e828a
#!/usr/bin/env rust-script
// summary : hello rust loops
// keywords : rust, loops, @testable
// publish : gist
// authors : David Crosson
// license : Apache NON-AI License Version 2.0 (https://raw.githubusercontent.com/non-ai-licenses/non-ai-licenses/main/NON-AI-APACHE2)
// id : 08b29534-8ae4-42f8-8ada-dd024d2e6e0f
// created-on : 2024-10-12T23:06:44+02:00
// managed-by : https://github.com/dacr/code-examples-manager
// run-with : ./$file
fn main() {
let mut i = 0;
loop {
println!("bad trip hello: {}", i);
i += 1;
if i > 5 {
break;
}
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment