A list of the most recently updated pages.
| Sep 13, 2026 | » | Weekly Syllabi
2 min; updated Sep 24, 2026
2026Sept 2026Week 4 (09/21 - 09/27)
Week 3 (09/14 - 09/20)
Week 2 (09/07 - 09/13)
|
| Sep 22, 2026 | » | Concurrency Concerns in C#
1 min; updated Sep 24, 2026
CancellationSourced from . Notes
References
|
| Sep 23, 2026 | » | Cancellation in .NET
7 min; updated Sep 23, 2026
OverviewCancellation is cooperative. One part of the code politely notifies the other code that it’d like it to please stop. The responding code may immediately stop, or continue until it reaches a valid stopping point, or ignore the cancellation request entirely. Most code has the form: … where the By convention, the |
| Sep 21, 2026 | » | OOP Creation Patterns: Singleton
2 min; updated Sep 21, 2026
SingletonSingleton ensures only one instance of a class exists. Useful when you need exactly one shared resource like a connection pool, logger, etc. Most times, passing shared objects through constructors is clearer, works, and easily testable. Sample… with usage: In multi-threaded scenarios, C# offers |
| Sep 21, 2026 | » | OOP Creation Patterns: Builder
2 min; updated Sep 21, 2026
Builder PatternShows up when designing things like HTTP requests, configuration objects, etc. Instead of a ctor with 10 parameters where half are null, you build the object incrementally, e.g., … with usage like: |
| Sep 6, 2026 | » | Hello Interview
4 min; updated Sep 21, 2026
System DesignSee for bite-sized groups that are digestible in a week’s period. In a Hurry
Core Concepts
Question Breakdowns
Patterns
Key Technologies
Advanced Topics
In the Wild
CodeTwo Pointers
Sliding Window
Intervals
Stack
Linked List
Binary Search
Heap
Depth-First Search
Breadth-First Search
Backtracking
Graphs
Dynamic Programming
Greedy Algorithms
Trie
Prefix Sum
Matrices
Low Level DesignLow Level Design in a HurryConcurrency
Problem Breakdowns
Behavioral
AI CodingOverview
Fundamentals
Common Patterns
AI Coding Problem Breakdowns
ML System DesignML System Design in a Hurry
ML System Design Core Concepts
ML System Design Question Breakdowns
References
|
| Sep 17, 2026 | » | Probability
1 min; updated Sep 21, 2026
Probability is a Fraction of a Finite SetA simplified definition: a probability is a fraction of a finite set. For example, in the 2024 GSS survey, of the 3,986 respondents, 42 were bankers. If we choose a person from this population at random, the probability that they are a bank teller is 1.054%. |
| Jul 25, 2021 | » | Eternals
8 min; updated Sep 17, 2026
Eternals Vol. 3 (2006).
Neil Gaiman; John Romita Jr..
Eternals Vol. 5 (2021).
Kieron Gillen; Esad Ribić.
SnapshotsOrigin of LifeMark Evanier: Can you prove that ancient civilizations weren’t visited by space travellers and heralded as gods? Did those aliens alight on this planet eons ago and plant the seeds of our civilization? ... |
| Nov 23, 2016 | » | What is Ergodicity?
3 min; updated Sep 17, 2026
A random process is ergodic if all of its statistics can be determined from a sample function of the process. That is, the ensemble averages equal the corresponding time averages with probability one. Role of Ergodicity in Human InferenceA newspaper has previously printed some inaccurate information, therefore, the newspaper is going to publish inaccurate information in the future. Fair; ensemble of published articles is more or less ergodic. More crimes are committed by black persons than by white persons, therefore each individual black person is not to be trusted? The ensemble of black people is not at all ergodic! ... |
| Sep 29, 2017 | » | The Bayes Formula
1 min; updated Sep 17, 2026
The FormulaBy definition… $$ \mathbb{P}(A) = \mathbb{P}(A \cap B) + \mathbb{P}(A \cap B^{c}) $$ From conditional probability … $$ \mathbb{P}(A) = \mathbb{P}(A|B) \ \mathbb{P}(B) + \mathbb{P}(A|B^c) \ \mathbb{P}(B^c) $$ Therefore $$ \mathbb{P}(B|A) = \frac{ \mathbb{P}(B \cap A) }{ \mathbb{P}(A) } $$ $$ = \frac{ \mathbb{P}(A|B) \mathbb{P}(B) }{ \mathbb{P}(A|B) \ \mathbb{P}(B) + \mathbb{P}(A|B^c) \ \mathbb{P}(B^c) } $$ Switching the roles of the events is convenient because in many problems, one of the conditional probabilities is easier to calculate. ... |
| Sep 29, 2017 | » | Conditional Probability
1 min; updated Sep 17, 2026
DefinitionWhere \( \mathbb{P}(A|B) \) is the probability of event \(A\) given that event \(B\) occurs: $$ \mathbb{P}(A|B) = \frac{\mathbb{P}(A \cap B)}{\mathbb{P}(B)} $$ Notice that if \(P(B) = 0\) then it’s meaningless to condition \(A\) on \(B\). Satisfying the Axioms of ProbabilityAxiom 1: Normalization$$ \mathbb{P}(B|B) = \frac{\mathbb{P}(B \cap B)}{\mathbb{P}(B)} = 1 $$ Axiom 2: Non-negativityBecause \(A \cap B \subseteq B \), then \( 0 \le \mathbb{P}(A|B) \le 1 \). ... |
| Oct 2, 2017 | » | The Binomial Random Variable
3 min; updated Sep 17, 2026
\(X\) is a binomial random variable if it takes the values \(0, 1, 2, …, n\) and $$ \mathbb{P}\{X = k\} = { n \choose k } \cdot p^k \cdot (1 - p)^{n-k} $$ Sanity Check: Do the probabilities sum to 1?$$ \sum_{k=0}^{n} \mathbb{P}\{X = k\} = \sum_{k=0}^{n} { n \choose k } p^k (1 - p)^{n-k} = \left( p + (1 - p) \right)^n = 1 $$ I totally didn’t understand how we got to \(\left( p + (1 - p) \right)^n\). In my notes, I simply noted “Calculus Theorem” and that was it. ლ(ಠ_ಠ ლ) ... |
| Oct 2, 2017 | » | Bernoulli Processes
3 min; updated Sep 17, 2026
Bernoulli ProcessA Bernoulli Process is a sequence of independent \({0, 1}\) - valued random variables \(X_1, X_2, X_3, …\), e.g. \(0, 0, 1, 0, 1, 1\) A Bernoulli Process does not mandate that the probability distributions of the \(X_i\) be identical. That is up to the model that we choose. For instance, the Binomial Random Variable assumes \(\mathbb{P}\{X_i = 1\} = p \ \ \forall i\) Suppose you flip a coin repeatedly, and record \(0\) for tails and \(1\) for heads. ... |
| Aug 29, 2026 | » | The Rape of Nanking
4 min; updated Sep 17, 2026
The Rape of Nanking.
Iris Chang.
Nov 21, 1997.
ISBN: 9780465068357 .
IntroductionWWII started on different days for different people. For Africans, 1935 when Mussolini invaded. For Europeans, Sept 1939 when Hitler invaded Poland. For Americans, Dec 1941 when Japan attacked Pearl Harbor. For Asians, 1931 when Japan occupied Manchuria. Kenyan schools taught 1939 as the start of WWII. ... |
| Sep 16, 2026 | » | Factory Method
1 min; updated Sep 16, 2026
A factory is a helper that makes the right kind of object for you so you don’t have to decide. That said, factories are polarizing because some engineers view them as examples of engineering. Simple FactoryFactory shows up when requirements say something like “support different notification types”, e.g., … where clients do |
| Aug 1, 1997 | » | [ToDo] Design Patterns: Elements of Reusable Object-Oriented Software
1 min; updated Sep 16, 2026
Design Pattern Catalog
Design Patterns: Elements of Reusable Object-Oriented Software.
Erich Gamma; Richard Helm; Ralph Johnson; John Vlissides.
|
| Sep 28, 2021 | » | Observer
8 min; updated Sep 16, 2026
Rant: some of willchan’s thoughts on WeakPtr, for those who care to read criticizes the observer pattern for murking dependency chains. Investigate more in this regard. IntentA one-to-many dependency between object so that when one object (subject) changes, all its dependents (observers) are notified and update automatically. ... |
| Sep 3, 2026 | » | Redis for System Design Problems
5 min; updated Sep 16, 2026
Redis BasicsRedis is a key-value store that lives in memory, and executes one command at a time. In-memory nature makes it very fast (a single node can handle 100K writes per second), while the sequential model makes it easy to reason about operations. Redis has two persistence modes. RDB takes periodic snapshots, and AOF logs
every write but only |
| Sep 13, 2026 | » | Dependency Inversion Principle
3 min; updated Sep 16, 2026
Dependency Inversion PrincipleYour code should depend on abstractions, not concrete implementations. Instead of: … have: … so that swapping out an Notes from ChromiumPhrased differently, inversion of control allows users of a framework/library
(clients) to customize the behavior of the framework. The control flow is
inverted because the library (e.g., |
| Mar 30, 2023 | » | Intro to Design Patterns
3 min; updated Sep 16, 2026
What Are Design Patterns?Arriving at designs that are specific to the problem at hand but general enough to address future problems and requirements is hard. New designers tend to be overwhelmed by the options available. Expert designers do not solve every problem from first principles; they reuse design patterns. I’ve also encountered the “you aren’t gonna need it” (YAGNI) school of thought that aims to minimize writing code that anticipates too far into the future, as such guesses usually don’t pan out. Design patterns seem like they exist somewhere between designing for now, and designing for a possible future. A design pattern solves a specific problem being encountered now. And even within a design pattern, one could still adhere to YAGNI, and add pieces when needed. When it does come to the point where the design needs more features, at least the design pattern provides a mental framework that is consistent with the initial design of the system. ... |
The General Social Survey (GSS) touts itself as the only full-probability, personal-interview survey designed to monitor changes in both social characteristics and attitudes currently being conducted in the US.
...