loading...

re: Explain like I'm five. What is a process and what is thread ? VIEW POST

FULL DISCUSSION
 

You are 5y old now, until you are 18 you are dependent and attached to your mother, she protects you from outside world, she delivers you the filtered messages and most important she decided what are your house chores.

You share the same house / environment and have access to the same rooms / books from the shelves and utilities (water, power etc).

Your mother consumes more resources than you and it's bigger of course. A mother can have multiple children, that consume fewer resources.

Mother - process
Kid - thread
House - RAM (is shared)
House chores - the data to execute / instructions


You can use threads directly example in Java/C++, but other languages have a smaller kind of threads. Example GO has goroutines, and the runtime can pack thousands of goroutines in a managed thread. From the programmer point of view there is no difference.

Code of Conduct Report abuse