educative.io

Ruby Concurrency for Senior Engineering Interviews (C. H. Afzal)


Bonus Questions - Ordered Printing This problem is about imposing an order on thread execution. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/qZ5Q9yqwG67). API Overview - ... continued This lesson continues the discussion on instantiating threads. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/N79Y5zrGkqL). API Overview - Thread Variables This lesson discusses thread-local variables. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/39vO9v0qrl4). Bonus Questions - Printing FooBar n Times This problem is about executing threads in an order for a user specified number of times. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/JPqnGRx23pJ). API Overview - ...continued This lesson continues the discussion of Mutex in Ruby. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/YMOrYl1Xgz9). The Basics - Moore’s Law Discusses impact of Moore's law on concurrency. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/YQ5Xw0r9wAp). Bonus Questions - Printing Number Series (Zero, Even, Odd) This problem is about repeatedly executing threads which print a specific type of number. Another variation of this problem; print even and odd numbers; utilizes two threads instead of three. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/qAlpZQWwV80). API Overview - Global Interpreter Lock This lesson discusses the global interpreter lock, also known as GIL and its effects. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/qVZVDo2OYn0). Interview Practice Problems - ... continued This lesson demonstrates how to implement consumer-producer problem using mutexes. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/YMgN9rR4y2p). API Overview - Quiz 4 Questions relating to the Threading API covered in this chapter. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/xVNoyxjxjJ3). API Overview - Quiz 2 Questions relating to the Threading API are covered in this lesson. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/mEBlNpl2OjG). The Basics - Mutex vs Monitor In this lesson, let's learn what a monitor is and how it is different than a mutex. Monitors are advanced concurrency constructs and specific to language frameworks. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/BnNqqNlp54Y). The Basics - Introduction This lesson introduces concurrency and provides motivational examples to further our understanding of concurrent systems. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/qVwGAp6qx5k). The Basics - Synchronous vs Asynchronous This lesson discusses the differences between asynchronous and synchronous programming, which are often talked about in the context of concurrency. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/B6Kx2KAR7Pn). The Basics - Throughput vs Latency This lesson discusses throughput and latency in the context of concurrent systems. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/7DYVQyR87Xr). The Basics - Deadlocks, Liveness & Reentrant Locks We discuss important concurrency concepts such as deadlock, liveness, live-lock, starvation, and reentrant locks in depth. Also included are executable code examples for illustrating these concepts. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/N7qL8k6BnPL). The Basics - Amdahl's Law Blindly adding threads to speed up program execution may not always be a good idea. In this lesson, let’s find out what Amdahl's Law says about parallelizing a program. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/BnBPkAoK8gY). API Overview - Creating Threads This lesson discusses the various ways in which we can create, run, prioritise and check the status of threads. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/g2vyAgjERVj). The Basics - Concurrency vs Parallelism This lesson clarifies the common misunderstandings and confusions around concurrency and parallelism. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/m2pVkWgOyvG). The Basics - Critical Sections & Race Conditions This lesson exhibits how incorrect synchronization in a critical section can lead to race conditions and buggy code. The concepts of the critical section and race condition are explained in depth. Also included is an executable example of a race condition. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/B6EzvwPlBQW). The Basics - Cooperative Multitasking vs Preemptive Multitasking This lesson details the differences between the two prevailing models of multitasking. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/3j2rK5MGXMA). The Basics - I/O Bound vs CPU Bound In this lesson, we delve into the characteristics of programs with different resource-use profiles and how that can affect program design choices. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/qVM5G3xMRpR). The Basics - Program vs Process vs Thread This lesson discusses the differences between a program, a process, and a thread. Also included is a pseudocode-example of a thread-unsafe program. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/qZOj43NLvMD). The Basics - Hoare vs Mesa Monitors This lesson looks at the different designs for implementing monitors. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/qVKQZnKykKy). The Basics - Semaphore vs Monitor This lesson discusses the differences between a monitor and a semaphore. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/Bn2WOlNY7kW). API Overview - Condition Variables This lesson explores the use of condition variables in Ruby. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/xopzpAlAB0l). Brief Intro to Asynchronous Programming - ... continued This lesson continues the discussion on asynchronous programming. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/3YxmZjOyv0n). API Overview - Monitor This lesson introduces the use of Monitor in Ruby. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/3YxPK4lxDQR). API Overview - Exception Handling in Threads This lesson discusses exception handling in threads. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/x1Wy1wvZ493). Interview Practice Problems - Thread-safe Singleton This lesson discusses correctly implementing a singleton pattern in Ruby. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/xVER6W44mRB). API Overview - Mutex This lesson discusses Mutex as used in Ruby. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/JYp5n38zPMg). Interview Practice Problems - Dining Philosophers This lesson discusses the famous Dijkstra's Dining Philosophers problem. Two different solutions are explained at length. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/x18zwqDmq5P). Interview Practice Problems - Multithreaded Merge Sort ​In this lesson, we will implement merge sort using multiple threads. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/7n77rz67WLO). API Overview - Quiz 3 Questions relating to the Threading API are covered in this lesson. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/JEkYqg9AkBg). Interview Practice Problems - Implementing a Barrier This lesson discusses how a barrier is implemented in Ruby. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/JEZKjWwlVk2). API Overview - Sleeping and Terminating Threads This lesson talks about putting threads to sleep and terminating them. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/mE08qz0wm8n). Interview Practice Problems - Rate Limiting Using Token Bucket Filter In this lesson, we will be ​ implementing rate limiting using a naive token bucket filter algorithm. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/qADGQXq0rq0). Interview Practice Problems - Uber Ride Problem This lesson solves the constraints of an imaginary Uber ride problem where Republicans and Democrats can't be seated as a minority in a four passenger car. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/7nV5Do8924A). Interview Practice Problems - Barber Shop This lesson visits the synchronization issues when programmatically modeling a hypothetical barber shop and how they can be solved using Ruby's concurrency primitives. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/Y5jBBNkjELM). Brief Intro to Asynchronous Programming - Fiber This lesson introduces the concept of Fibers in Ruby, which is, in a sense, the equivalent of coroutines. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/qZXZxxM52G3). Interview Practice Problems - Unisex Bathroom Problem In this lesson, we will look at a synchronization practice problem requiring us to synchronize the usage of a single bathroom by both genders. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/3YrZonDAPq4). API Overview - Quiz 1 Questions relating to the Threading API are covered in this lesson. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/m2LAPKBGlpR). Brief Intro to Asynchronous Programming - Introduction This lesson introduces the concept of asynchronous programming as an important programming paradigm. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/JE5oYlZvxw2). Interview Practice Problems - Asynchronous to Synchronous Problem In this lesson, we will study a​ real-life interview question asking to convert asynchronous execution to synchronous execution. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/mEqypxEGyGR). Epilogue - Acknowledgements Final thoughts and acknowledgements. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/3jLN9wN0Pmp). Interview Practice Problems - Implementing Semaphore In this lesson, you will learn how to design and implement a simple semaphore class in Ruby. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/RLr5rqDJOQE). Interview Practice Problems - Blocking Queue | Bounded Buffer | Consumer Producer Classical synchronization problem involving a limited size buffer which can have items added to it or removed from it by different producer and consumer threads. This problem is known by different names: blocking queue problem, bounded buffer problem or consumer producer problem. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/g2OP9zo2Vnk). Interview Practice Problems - Thread Safe Deferred Callback Asynchronous programming involves being able to execute functions at a future occurrence of some event. Designing a thread-safe deferred callback class becomes a challenging interview question ​and we will learn about it in this lesson​ . View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/3jXNOnmQyzx). The Basics - Mutex vs Semaphore The concept of and the differences between a mutex and a semaphore will befuddle most developers. In this lesson, we discuss the differences between the two most fundamental concurrency constructs offered by almost all language frameworks. Difference between a mutex and a semaphore makes a pet interview question for senior engineering positions! View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/RM79KgV4BWO). Interview Practice Problems - ReadWrite Lock ​In this lesson, ​ we discuss a common interview question involving the synchronization of multiple reader threads and a single writer thread. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/3YkWnYZKzo4). Bonus Questions - Build a Molecule This problem simulates the creation of water molecule by grouping three threads representing Hydrogen and Oxygen atoms. View the lesson [here](https://www.educative.io/courses/ruby-concurrency-for-senior-engineering-interviews/B1YmWEnQl5k).
About the Ruby Concurrency for Senior Engineering Interviews (C. H. Afzal) category [Ruby Concurrency for Senior Engineering Interviews (C. H. Afzal)] (1)