This course develops the mathematical tools needed to count, measure uncertainty, and reason about random processes, which are central to computer science, data analysis, and algorithm design. Building on the logical foundations from the first course, it introduces combinatorial counting techniques and probability theory through a discrete, computation-oriented lens.
The course begins with the fundamentals of counting, including the product rule, sum rule, permutations, combinations, and binomial coefficients. You will learn how to count complex structures efficiently using techniques such as the principle of inclusion and exclusion, with applications ranging from algorithm analysis to data organization.
The second half of the course focuses on probability, emphasizing its deep connection to counting. Topics include sample spaces, events, conditional probability, independence, and Bayes’ Theorem. You will also study random variables, probability distributions, expectation, and variance, gaining tools to model and analyze randomized algorithms and real-world uncertainty.
Throughout the course, abstract concepts are reinforced with concrete examples drawn from computing, games of chance, and classic probability puzzles. By the end, learners will be able to systematically count possibilities, compute probabilities, and reason rigorously about randomness—skills essential for advanced study in algorithms, data science, machine learning, and beyond.
This module teaches how to count arrangements, selections, and possibilities using permutations, combinations, binomial coefficients, and inclusion-exclusion.
It covers probability fundamentals, conditional probability, random variables, and iconic problems like the Monty Hall dilemma to handle uncertainty.
These tools are crucial for analyzing algorithm efficiency, game design, randomized systems, machine learning, and risk assessment.
涵盖的内容
1篇阅读材料
显示有关单元内容的信息
1篇阅读材料•总计10分钟
Introduction to Discrete Math for Computer Science (Counting & Probability)•10分钟
Basics of Counting
第 2 单元•小时 后完成
单元详情
Counting techniques provide systematic methods for determining the number of possible outcomes in discrete structures. This topic introduces basic counting principles such as the sum rule and product rule.
涵盖的内容
15个视频1篇阅读材料1个作业
显示有关单元内容的信息
15个视频•总计41分钟
Basics of Counting Overview•3分钟
Basics of Counting_intro•8分钟
Product Rule_Intro, Example1 & 2•1分钟
(Optional) Product Rule_Example3 & 4•2分钟
(Optional) Product Rule_Example5 & 6•2分钟
Sum Rule_Example•1分钟
(Optional) Using Both Product and Sum Rules_Example1•2分钟
(Optional) Using Both Product and Sum Rules_Example2•3分钟
(Optional) InclassEx•2分钟
Tree Diagrams_Intro, Example1 & 2•3分钟
The Pigeonhole Principle_Intro & Example1•2分钟
(Optional) The Pigeonhole Principle_Example2•2分钟
(Optional) The Pigeonhole Principle_Example3•3分钟
The Pigeonhole Principle_Generalized Pigeonhole Principle_Intro & Example1•3分钟
(Optional) The Pigeonhole Principle_Generalized Pigeonhole Principle_Example2 & 3•5分钟
1篇阅读材料•总计30分钟
Basics of Counting•30分钟
1个作业•总计20分钟
Quiz 1•20分钟
Permutations and Combinations
第 3 单元•小时 后完成
单元详情
This topic studies methods for counting arrangements and selections of objects. It distinguishes between ordered and unordered selections and introduces formulas for permutations and combinations.
Combinations_Combinatorial Proof and Bijection Principle_Intro & Examples•5分钟
Generalized Permutations and Combinations_Permutations with Indistinguishable Objects_Intro & Example•4分钟
Generalized Permutations and Combinations_Distributing Objects into Boxes_Intro & Example•2分钟
Generalized Permutations and Combinations_Indistinguishable objects Distinguishable boxes_Theorem & Example•8分钟
Generalized Permutations and Combinations_Combinations with Repetition_Intro & Examples•3分钟
(Optional) InclassEx•5分钟
1篇阅读材料•总计30分钟
Permutations and Combinations•30分钟
1个作业•总计20分钟
Quiz 2•20分钟
Binomial Coefficients
第 4 单元•小时 后完成
单元详情
Binomial coefficients arise in counting combinations and in the expansion of binomial expressions. This topic covers the binomial theorem, Pascal’s identity, and important combinatorial identities.
Pascal’s Identity and Triangle_Pascal's Identity & Combinatorial proof of Pascal’s identity•11分钟
Pascal’s Identity and Triangle_Pascal’s Triangle•1分钟
Some Other Identities_Vandermonde's Identity•6分钟
Some Other Identities_Vandermonde's Identity_Corollary•3分钟
Some Other Identities_Counting bit strings & Proof•9分钟
(Optional) InclassEx•5分钟
1篇阅读材料•总计30分钟
Binomial Coefficients•30分钟
1个作业•总计30分钟
Quiz 3•30分钟
The Inclusion-Exclusion Principle
第 5 单元•小时 后完成
单元详情
The inclusion–exclusion principle provides a systematic way to count elements in overlapping sets. It is widely used in counting problems involving unions of multiple sets.
涵盖的内容
13个视频1篇阅读材料1个作业
显示有关单元内容的信息
13个视频•总计78分钟
The Inclusion-Exclusion Principle Overview•3分钟
The Inclusion-Exclusion Principle_Intro•1分钟
Two Finite Sets_Intro & Examples•3分钟
Three Finite Sets_Intro•3分钟
(Optional) Three Finite Sets_Example•2分钟
Inclusion-Exclusion Principle_Theorem•6分钟
Inclusion-Exclusion Principle_Proof•8分钟
Number of Onto Functions_Intro & Example1•14分钟
(Optional) Number of Onto Functions_Example2•2分钟
Derangement_Example1 & Proof•15分钟
(Optional) Derangement_Example2•2分钟
Probability of a derangement•3分钟
(Optional) InclassEx•18分钟
1篇阅读材料•总计30分钟
The Inclusion-Exclusion Principle•30分钟
1个作业•总计20分钟
Quiz 4•20分钟
Introduction to Probability
第 6 单元•小时 后完成
单元详情
This topic introduces probability as a measure of uncertainty based on counting outcomes. It defines experiments, sample spaces, events, and basic probability rules.
涵盖的内容
21个视频1篇阅读材料1个作业
显示有关单元内容的信息
21个视频•总计68分钟
Introduction to Probability Overview•2分钟
The Hatcheck Problem Revisited•1分钟
Probability_Definitions•2分钟
(Optional) Probability_Example•2分钟
Poker_Intro•3分钟
(Optional) Poker_Ex1•4分钟
(Optional) Poker_Ex2•6分钟
(Optional) Poker_Ex3•5分钟
(Optional) Poker_Ex4•4分钟
Mark Six•4分钟
Sampling with/without replacement•1分钟
Complement of Event_Theorem•2分钟
(Optional) Complement of Event_Example•2分钟
Union of Events & Inclusion-Exclusion Principle for Probability, Complement and Union Events•4分钟
Probability Distribution•2分钟
Uniform Distribution & Non-Uniform Distribution•2分钟
Probability of an Event•2分钟
Independence_Definition•2分钟
(Optional) Independence_Examples•6分钟
Pairwise and Mutual Independence•6分钟
(Optional) InclassEx•6分钟
1篇阅读材料•总计10分钟
Introduction to Probability•10分钟
1个作业•总计20分钟
Quiz 5•20分钟
Conditional Probability and Bayes' Theorem
第 7 单元•小时 后完成
单元详情
Conditional probability measures the likelihood of events given prior information. This topic introduces independence and Bayes’ theorem, enabling probabilistic reasoning in real-world decision making.
涵盖的内容
15个视频1篇阅读材料1个作业
显示有关单元内容的信息
15个视频•总计69分钟
Conditional Probability and Bayes' Theorem Overview•5分钟
Conditional Probability and Bayes' Theorem_Intro•1分钟
Random variables assign numerical values to outcomes of random experiments. This topic covers discrete and continuous distributions, expectation, and variance, forming the foundation of probability modeling.
涵盖的内容
28个视频1篇阅读材料1个作业
显示有关单元内容的信息
28个视频•总计132分钟
Random Variables Overview•3分钟
Random Variables•2分钟
Distribution of a Random Variable•1分钟
Bernoulli Trials•4分钟
Binomial Distribution_Theorem & Example•3分钟
Continuous Probability Distribution•3分钟
Infinite Sample Space•3分钟
Geometric Distribution•2分钟
Expected Value_Definition, Theorem & Example•8分钟
Expected Value_Example_Binomial Distribution•2分钟
Linearity of Expectations_Theorem & Proof•4分钟
Indicator Random Variables_Intro•3分钟
(Optional) Indicator Random Variables_Example_the Hatcheck Problem•4分钟
(Optional) Indicator Random Variables_Example_Hiring Problem•15分钟
(Optional) Indicator Random Variables_Example_Balls and Bins•4分钟
Average-case Analysis of Algorithms_Definition & Example_Linear Search•8分钟
(Optional) Average-case Analysis of Algorithms_Example_Insertion Sort•8分钟
HKUST is a world-class research-intensive university that focuses on science, technology, and business as well as humanities and social science. HKUST offers an international campus, and a holistic and interdisciplinary pedagogy to nurture well-rounded graduates with a global vision, a strong entrepreneurial spirit, and innovative thinking.
When will I have access to the lectures and assignments?
To access the course materials, assignments and to earn a Certificate, you will need to purchase the Certificate experience when you enroll in a course. You can try a Free Trial instead, or apply for Financial Aid. The course may offer 'Full Course, No Certificate' instead. This option lets you see all course materials, submit required assessments, and get a final grade. This also means that you will not be able to purchase a Certificate experience.
What will I get if I subscribe to this Specialization?
When you enroll in the course, you get access to all of the courses in the Specialization, and you earn a certificate when you complete the work. Your electronic Certificate will be added to your Accomplishments page - from there, you can print your Certificate or add it to your LinkedIn profile.
Is financial aid available?
Yes. In select learning programs, you can apply for financial aid or a scholarship if you can’t afford the enrollment fee. If fin aid or scholarship is available for your learning program selection, you’ll find a link to apply on the description page.