Get the latest tech news

Make your program slower with threads (2014)


, while taking a numerical methods course, I wrote some code to calculate the expected number of shared birthdays in a group. The code is very simple: each attempt constructs a vector of N birthdays, then counts the duplicates.

Years ago, while taking a numerical methods course, I wrote some code to calculate the expected number of shared birthdays in a group. The outer loop runs millions of attempts, and calculates the mean number of shared birthdays across all the samples. At worst, it’s tempting to think, these things count as a non-parallel portion of code and lower the maximum achievable parallel speedup.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of Threads

Threads

Photo of program

program

Related news:

News photo

Shopify is acquiring the Threads team

News photo

Twitch announces a program allowing DJs to split revenue with record labels

News photo

Democrat calls only 7 EV-charging stations deployed under US program 'pathetic'