© Ali Asad and Hamza Ali 2017

Ali Asad and Hamza Ali, The C# Programmer’s Study Guide (MCSD), 10.1007/978-1-4842-2860-9_8

8. Multithreaded, Async & Parallel Programming

Ali Asad and Hamza Ali1

(1)Sialkot, Pakistan

In this chapter, we’ll learn how to increase the performance of complicated and time-consuming operations of an application by:

  1. Working with Threads

  2. Working with Task

  3. Making UI Responsive (async and await)

  4. Using Parallel Programming

Working with Threads

A thread controls the flow of an executable program. By default, a program has one thread called Main Thread. Main Thread starts when control enters in the Main method and it terminates when Main method returns.

If the execution of a program is controlled by more than one thread, it’s called ...

Get The C# Programmer’s Study Guide (MCSD): Exam: 70-483 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.