Practicing and exploring
Test your knowledge and understanding by answering some questions, get some hands-on practice, and explore this chapter's topics with deeper research.
Exercise 12.1 - test your knowledge
Answer the following questions:
- By convention, what suffix should be applied to a method that returns
Task
orTask<T>
? - To use the
await
keyword inside a method, what keyword must be applied to the method declaration? - How do you create a child task?
- Why should you avoid the
lock
keyword? - When should you use the
Interlocked
class?
Exercise 12.2 - explore topics
Use the following links to read more about this chapter's topics:
- Threads and threading: https://msdn.microsoft.com/en-us/library/6kac2kdh(v=vs.110).aspx
- Task parallelism (task parallel library) ...
Get C# 7 and .NET Core: Modern Cross-Platform Development - Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.