Skip to content

Commit

Permalink
Merge pull request #3711 from miketon/main
Browse files Browse the repository at this point in the history
Update loop to Result: 10
  • Loading branch information
chriskrycho committed Mar 28, 2024
2 parents d1770c8 + a80a425 commit 529b9e0
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ fn main() {
let counter = Arc::new(Mutex::new(0));
let mut handles = vec![];

for _ in 0..10 {
for _ in 0..=10 {
let counter = Arc::clone(&counter);
let handle = thread::spawn(move || {
let mut num = counter.lock().unwrap();
Expand Down

0 comments on commit 529b9e0

Please sign in to comment.