Navigation Menu

Search code, repositories, users, issues, pull requests..., provide feedback.

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly.

To see all available qualifiers, see our documentation .

  • Notifications You must be signed in to change notification settings

This repository is a compilation of my solutions to the Data Structures and Algorithms assignments offered by the University of California, San Diego (UCSD) and the National Research University Higher School of Economics (HSE) on Coursera. These assignments, covering material from courses 1 through 6, have all been solved using the Python.

TZhoroev/Coursera-Data_Structures_and_Algorithms

Folders and files, repository files navigation, coursera-data_structures_and_algorithms.

Plot

This repository contains my solutions to the Data Structures and Algorithms assignments offered by the University of California, San Diego (UCSD) and the National Research University Higher School of Economics (HSE) on Coursera. All of the problems from courses 1 through 6 have been solved using Python.

These solutions are intended to serve as a reference for those working on these assignments or seeking an alternative perspective on how to approach the problems. It is recommended that you try solving the assignments independently before consulting these solutions, as the best way to improve your skills is through practice. However, if you encounter difficulties or require additional guidance, these solutions are available for reference.

I hope that this repository proves to be a useful resource for your studies in data structures and algorithms.

Algorithmic Toolbox : Certificate

This online course covers basic algorithmic techniques and ideas for computational problems arising frequently in practical applications: sorting and searching, divide and conquer, greedy algorithms, dynamic programming.

Week 1: Welcome

  • Sum of Two Digits .
  • Maximum Pairwise Product .

Week 2: Algorithmic Warm-up

  • Fibonacci Number
  • Last Digit of a Large Fibonacci Number
  • Greatest Common Divisor
  • Least Common Multiple
  • Fibonacci Number Again
  • Last Digit of the Sum of Fibonacci Numbers Again

Week 3: Greedy Algorithms

  • Money Change
  • Maximum Value of the Loot
  • Car Fueling
  • Maximum Advertisement Revenue
  • Collecting Signatures
  • Maximum Number of Prizes
  • Maximum Salary

Week 4: Divide and Conquer

  • Binary Search
  • Binary Search with Duplicates
  • Majority Element
  • Improving Quick Sort
  • Number of Inversions
  • Organizing a Lottery
  • Closest Points

Week 5: Dynamic Programming I

  • Money Change Again
  • Primitive Calculator
  • Edit Distance
  • Longest Common Subsequence of Two Sequences
  • Longest Common Subsequence of Three Sequences

Week 6: Dynamic Programming II

  • Maximum Amount of Gold
  • Partitioning Souvenirs
  • Maximum Value of an Arithmetic Expression

Data Structures : Certificate

In this online course, we consider the common data structures that are used in various computational problems.

Week 1: Basic Data Structures

  • Check brackets in the code
  • Compute tree height
  • Network packet processing simulation
  • Extending stack interface
  • Maximum in Sliding Window

Week 2: Priority Queues and Disjoint Sets

  • Convert array into heap
  • Parallel processing
  • Merging tables

Week 3: Hash Tables and Hash Functions

  • Hashing with chains
  • Find pattern in text
  • Substring equality
  • Longest common substring
  • Pattern matching with mismatches

Week 4: Binary Search Trees

  • Binary tree traversals
  • Is it a binary search tree?
  • Is it a binary search tree? Hard version
  • Set with range sums

Algorithms on Graphs : Certificate

In this online course, first learned what a graph is and what are some of the most important properties. Then we learned several ways to traverse graphs and how one can do useful things while traversing the graph in some order. Then we learned shortest paths algorithms — from the basic ones to those which open door for 1000000 times faster algorithms used in Google Maps and other navigational services. We finished with minimum spanning trees which are used to plan road, telephone and computer networks and also find applications in clustering and approximate algorithms.

Week 1: Decomposition of Graphs I

  • Finding an Exit from a Maze
  • Adding Exits to a Maze

Week 2: Decomposition of Graphs II

  • Checking Consistency of CS Curriculum
  • Determining an Order of Courses
  • Checking Whether Any Intersection in a City is Reachable from Any Other

Week 3: Paths in Graphs I

  • Computing the Minimum Number of Flight Segments
  • Checking whether a Graph is Bipartite

Week 4: Paths in Graphs II

  • Computing the Minimum Cost of a Flight
  • Detecting Anomalies in Currency Exchange Rates
  • Exchanging Money Optimally

Week 5: Minimum Spanning Trees

  • Building Roads to Connect Cities

Week 6: Advanced Shortest Paths

  • Friend Suggestion
  • Compute Distance Faster Using Coordinates
  • Compute Distance with Preprocessing
  • Compute Distance with Preprocessing on Larger Road Networks
  • Travelling Salesman Problem

Algorithms on Strings : Certificate

Textual information abounds in the world and on the internet. We read webpages, books, emails, and textual inquiries to conduct information searches. From the perspective of computer science, each of those are strings. Search engines employ a variety of string algorithms to make sense of all that data and improve the effectiveness of searches. In addition, a variety of search methods are used in the developing field of personalized medicine to identify mutations in the human genome that cause disease. You will master important pattern matching ideas in this online course, including attempts, suffix trees, suffix arrays, and even the Burrows-Wheeler transform.

Week 1: Suffix Trees

  • Construct a Trie from a Collection of Patterns
  • Implement TrieMatching
  • Extend TrieMatching
  • Construct the Suffix Tree of a String
  • Find the Shortest Non-Shared Substring of Two Strings

Week 2: Burrows–Wheeler Transform and Suffix Arrays

  • Construct the Burrows–Wheeler Transform of a String
  • Reconstruct a String from its Burrows–Wheeler Transform
  • Implement BetterBWMatching
  • Construct the Suffix Array of a String

Week 3 & 4: Algorithmic Challenges: Suffix Arrays

  • Find All Occurrences of a Pattern in a String
  • Construct the Suffix Array of a Long String
  • Pattern Matching with the Suffix Array
  • Construct the Suffix Tree from the Suffix Array

Advanced Algorithms and Complexity : Certificate

Week 1: flows in networks.

  • Evacuating People
  • Assigning Airline Crews to Flights
  • Stock Charts

Week 2: Linear Programming

  • Infer Energy Values of Ingredients
  • Optimal Diet Problem
  • Online Advertisement Allocation

Week 3: NP-completeness

  • Assign Frequencies to the Cells of a GSM Network
  • Cleaning the Apartment
  • Advertisement Budget Allocation

Week 4: Coping with NP-completeness

  • Integrated Circuit Design
  • Plan a Fun Party
  • Reschedule the Exams

Week 5: Streaming Algorithms

  • Nice vs Naughty

Genome Assembly Programming Challenge : Certificate

Plot

Week 1: Assembling phi X174 Using Overlap Graphs

  • Assembling the phi X174 Genome from Error-Free Reads Using Overlap Graphs
  • Assembling the phi X174 Genome from Error-Prone Reads Using Overlap Graphs

Week 2: Assembling Genomes Using de Bruijn Graphs

  • Puzzle Assembly
  • Finding an Eulerian Cycle in Directed Graph
  • Finding a k-Universal Circular String
  • Assembling the phi X174 Genome from its k-mer Composition

Week 3: Genome Assembly Faces Real Sequencing Data

  • Finding a Circulation in a Network
  • Selecting the Optimal k-mer Size
  • Bubble Detection
  • Tip Removal
  • Assembling the phi X174 Genome from Error-Prone Reads using de Bruijn Graphs
  • Python 61.9%

Ace your Coding Interview

  • DSA Problems
  • Binary Tree
  • Binary Search Tree
  • Dynamic Programming
  • Divide and Conquer
  • Linked List
  • Backtracking

Data Structures and Algorithms Problems

  • TopClassic, TopLiked ↗ Easy
  • TopLiked ↗ Medium
  • TopLiked ↗ Easy
  • TopClassic, TopLiked ↗ Medium
  • ↗ Medium
  • ↗ Hard
  • ↗ Easy
  • TopAlgo ↗ Easy
  • TopClassic ↗ Medium
  • TopAlgo, TopClassic, TopAlgo ↗ Easy
  • TopLiked ↗ Hard
  • TopClassic, TopLiked ↗ Hard
  • TopClassic ↗ Hard
  • TopClassic ↗ Easy
  • TopAlgo ↗ Medium
  • TopClassic Hard
  • ↗ Beginner
  • TopAlgo ↗ Hard
  • TopLiked Medium
  • TopClassic, TopLiked, TopDP ↗ Medium
  • TopLiked, TopDP ↗ Hard
  • TopClassic, TopLiked, TopDP ↗ Hard
  • TopDP ↗ Medium
  • TopAlgo Medium
  • TopClassic Medium
  • TopAlgo Hard

Rate this post

Average rating 4.88 /5. Vote count: 5940

No votes so far! Be the first to rate this post.

We are sorry that this post was not useful for you!

Tell us how we can improve this post?

Thanks for reading.

To share your code in the comments, please use our online compiler that supports C, C++, Java, Python, JavaScript, C#, PHP, and many more popular programming languages.

Like us? Refer us to your friends and support our growth. Happy coding :)

guest

IMAGES

  1. SOLUTION: Data structure assignment flowchart

    data structure assignment solution

  2. Data Structure Assignment

    data structure assignment solution

  3. SOLUTION: Assignment data structure

    data structure assignment solution

  4. Why do students need help with a data structure assignment? » TechyLoud

    data structure assignment solution

  5. SOLUTION: Data structure assignment flowchart

    data structure assignment solution

  6. SOLUTION: Assignment 1 data structure

    data structure assignment solution

VIDEO

  1. Data Structure 2025 1st Lec1 Pt2

  2. DATA STRUCTURE ASSIGNMENT

  3. Data Structure 2025 1st Lec1 Pt1

  4. Data Structure

  5. ||DATA STRUCTURE AND APPLICATION||VIDEO ASSIGNMENT||FROM RESEARCH PAPER||KEERTHANA KS||SVCE BANGLORE

  6. ATOMIC STRUCTURE & ASSIGNMENT ONE SHORT VIDEO || CPET ODISHA & CUET 2025 || PYQ