← Questions

Run a function on several threads and inspect them on Linux

0
CoreWeaveCodingLast asked Sep 2026

You are given a function and asked to call it on several threads at once using only the basic thread primitives of your language (no thread or process pools, no asyncio). Start the threads, pass them their arguments, wait for them to finish and collect what they return or raise.

Then explain how you would see those threads from the shell on Linux while the program runs: which tools and /proc entries show a process's threads and their state.

Write and test your solution herePython in your browser, the question's tests level by level, every submission kept for you.Sign in to start coding