Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- constant TIMES = 1000_000;
- constant CORES = 1;
- my @results = await ^CORES .map: {
- start ^(TIMES / CORES) .map({ rand**2 + rand**2 }).grep: * < 1;
- };
- say ([+] @results) / TIMES * 4;
- say now - INIT now;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement