

Урок без названия
Presentation
•
Other
•
KG
•
Practice Problem
•
Hard
Khumoyun Aminaddinov
FREE Resource
12 Slides • 0 Questions
1
Tutorial – 2
Solving problems on O, o, Ω, Θ notations
Programming simple graph types
Mr. Khumoyun Aminaddinov
2
Computing Fibonacci
numbers
● What is Big-O ?
● What is small o ?
● What is omega ?
● What is theta ?
O(n)
3
Let’s recap:
● Asymptotics
https://www.geeksforgeeks.org/diff
erence-between-big-oh-big-omega-
and-big-theta/
4
5
Let’s recap:
● Asymptotics
● Comparison
6
Let’s recap:
● What is graph ?
● Why we need them ?
7
Task 1
Depth First Search or DFS for a Graph.
Depth First Traversal (or DFS) for a graph is similar to
Depth First Traversal of a tree. The only catch here is,
that, unlike trees, graphs may contain cycles (a node
may be visited twice). To avoid processing a node more
than once, use a boolean visited array. A graph can have
more than one DFS traversal.
8
Task 2
Shortest path in a Binary Maze
Given an MxN matrix where each element can either be
0 or 1. We need to find the shortest path between a
given source cell to a destination cell. The path can only
be created out of a cell if its value is 1.
9
Task 3
Print all paths from a given source to a
destination
Given a directed graph, a source vertex ‘s’ and a
destination vertex ‘d’, print all paths from given ‘s’ to ‘d’.
Consider the following directed graph. Let the s be 2
and d be 3. There are 3 different paths from 2 to 3.
10
Task 4
Find the number of islands
using DFS
Given a binary 2D matrix, find the number of islands. A
group of connected 1s forms an island. For example,
the below matrix contains 4 islands.
11
Task 5
How to find Shortest Paths from
Source to all Vertices using
Dijkstra’s Algorithm
Given a graph and a source vertex in the graph, find the
shortest paths from the source to all vertices in the
given graph.
12
Tutorial – 2
Solving problems on O, o, Ω, Θ notations
Programming simple graph types
Mr. Khumoyun Aminaddinov
Show answer
Auto Play
Slide 1 / 12
SLIDE
Similar Resources on Wayground
8 questions
6.7-- Transformations of quadratic functions
Presentation
•
9th Grade
10 questions
Equations Of All Kinds!!!
Presentation
•
8th Grade
10 questions
Long Division
Presentation
•
3rd - 4th Grade
8 questions
CLC to Stage 11 summary
Presentation
•
8th - 10th Grade
9 questions
The Mass
Presentation
•
5th Grade
11 questions
Problem Solving
Presentation
•
4th Grade
8 questions
Are you adventurous?
Presentation
•
University
9 questions
text and graphic features
Presentation
•
3rd Grade
Popular Resources on Wayground
6 questions
Secondary Safety Quiz
Presentation
•
9th - 12th Grade
10 questions
Afterschool Activities & Sports
Quiz
•
6th - 8th Grade
19 questions
ROAR Week 2026
Quiz
•
9th - 12th Grade
20 questions
Lab Safety Quiz
Quiz
•
6th Grade
15 questions
Cool Tool:Chromebook
Quiz
•
6th - 8th Grade
22 questions
would you rather
Quiz
•
3rd - 11th Grade
21 questions
Continents and Oceans
Quiz
•
6th Grade
20 questions
Parts of Speech
Quiz
•
5th Grade
Discover more resources for Other
20 questions
Place Value
Quiz
•
KG - 3rd Grade
6 questions
We don't eat our CLASSMATES
Quiz
•
KG
88 questions
FMS - Math Facts
Quiz
•
KG - 8th Grade
12 questions
Name that Candy
Quiz
•
KG - 12th Grade
10 questions
Would you rather...
Quiz
•
KG - University
10 questions
Place Value: Hundreds, Tens, and Ones
Quiz
•
KG - 2nd Grade
10 questions
NOUN
Quiz
•
KG
11 questions
Colors in Spanish - Los Colores
Quiz
•
KG - 2nd Grade