Homework #1 Due Monday 9/12/2011 In-Class

  1. In a C program, what is the purpose of the main() function? Why is it termed "main"?

  2. If we have a process that contains two threads, A and B, how can thread a get a variable local to only thread A and not shared (e.g. changeable) by thread B? That is, where would the variable be stored?

  3. What state do threads share? What states do they not share? (Hint: If you can answer this question, you should be able to answer the previous question.)