Skip to content

Latest commit

Β 

History

10 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Data Structures and Algorithms

This repository contains comprehensive coursework, exercises, and projects for a Data Structures and Algorithms course using C++. The materials demonstrate progressive learning from basic data structures to advanced algorithms and complex problem-solving techniques.

πŸ“ Repository Structure

πŸ“š In-Class Exercises (inclass/)

Structured learning progression with hands-on implementations

[Inclass03] Search & Sort Pre-Intermediate

[Inclass04] Linked List Beginner

  • MuaCom: Rice purchase simulation system
    • Basic linked list operations
    • Real-world application modeling

[Inclass05] Doubly Linked List Beginner

  • ListofProvinces: Vietnam provinces management
    • Doubly linked list implementation
    • Population and area statistics
    • Geographic data manipulation

[Inclass06] Stack and Queue

[Inclass07] Binary Search Tree Beginner

  • Introduction to BST concepts and basic operations
  • Tree traversal algorithms

[Inclass08] Binary Search Tree Pre-Intermediate

  • Advanced BST operations and balancing concepts

[Inclass09] Hash Table

[Inclass10] Binary Search Tree (Pre-Intermediate Cont.)

  • Continued advanced BST topics and applications

[Inclass11] Hash Table (Pre-Intermediate)

[Inclass12] Simple Graphs (For Beginners)

[Inclass13] Simple Graphs (Pre-Intermediate)

  • Graph traversal algorithms (DFS, BFS)
  • Path finding and connectivity

[Inclass14] Simple Graphs (Intermediate)

  • Advanced graph algorithms and optimization

[Inclass15] Simple Graphs (Intermediate Cont.)

  • Complex graph problems and real-world applications

πŸ“ Homework Assignments (homework/)

Comprehensive problem-solving and algorithm implementation

[Homework01] SearchSort Intermediate Part01

[Homework02] List Stack Queue Intermediate

[Homework03] Binary Search Tree (Intermediate)

[Homework04] Hash Table + Graph (Intermediate)

Advanced data structure combinations


πŸ”§ Practice Problems (practice/)

Comprehensive algorithm practice and optimization

Core Algorithm Implementations

  • LT-Search&Sort.cpp: Complete search and sorting algorithms

    • Binary Search, Linear Search
    • Selection Sort, Insertion Sort, Quick Sort, Merge Sort, Bubble Sort
    • Performance analysis and optimization
  • LT-BT-LinkedList.cpp: Advanced linked list operations

    • Find elements from end, middle detection
    • List copying and concatenation
    • Data swapping and reversal
    • Subsequence detection
    • Longest increasing subsequence
  • LT-BT-Stack&Queue.cpp: Stack and queue mastery

    • Expression evaluation and conversion
    • Bracket validation systems
    • Number base conversion
    • Concert visibility algorithms
  • HashTable.cpp: Hash table implementation patterns

    • Multiple collision resolution techniques
    • Load factor optimization
    • Performance benchmarking

🎯 Learning Progression

Foundation Level (Inclass 03-06)

  • Search & Sort Fundamentals: Basic algorithms and complexity analysis
  • Linear Data Structures: Arrays, linked lists, stacks, and queues
  • Problem-Solving Patterns: Real-world application modeling

Intermediate Level (Inclass 07-11)

  • Tree Structures: Binary search trees and traversal algorithms
  • Hash Tables: Collision resolution and optimization techniques
  • Advanced Operations: Complex data manipulation and efficiency

Advanced Level (Inclass 12-15)

  • Graph Theory: Representation, traversal, and pathfinding
  • Algorithm Optimization: Advanced techniques and performance tuning
  • System Integration: Combining multiple data structures

πŸ—οΈ Key Project Highlights

Mathematical Systems

  • Polynomial Calculator: Complete algebraic operations using linked lists
  • Expression Evaluator: Stack-based mathematical expression processing
  • Number System Converter: Multi-base conversion algorithms

Management Systems

  • Student Information: Hash table-based student record management
  • Inventory Control: Advanced sorting and searching for product management
  • Province Database: Geographic data processing with doubly linked lists

Algorithm Optimization Projects

  • City Renovation: Complex optimization using mathematical algorithms
  • Concert Visibility: Stack-based geometric problem solving
  • Graph Applications: Real-world network and connectivity problems

πŸ› οΈ Development Environment

Prerequisites

  • Compiler: GCC/G++ with C++11 standard or higher
  • Debugger: GDB for debugging support
  • IDE: Visual Studio Code with C++ extensions
  • Build System: CodeBlocks project files included

Project Configuration

Each directory includes:

  • .vscode/launch.json: Debug configuration for VS Code
  • *.cbp: CodeBlocks project files
  • Build scripts for compilation
  • External console output configuration

Running the Code

# Navigate to specific exercise directory
cd "inclass/[Inclass06] Stack and Queue"

# Compile with GCC
g++ -std=c++11 -g -Wall source_file.cpp -o output

# Run with debugging
gdb ./output

# Or use VS Code integrated debugging (F5)

πŸ“Š Topics Covered

Data Structures

  • Linear: Arrays, Linked Lists, Stacks, Queues
  • Non-Linear: Binary Search Trees, Graphs
  • Hash-Based: Hash Tables with various collision resolution methods

Algorithms

  • Search: Linear, Binary, Hash-based searching
  • Sort: Bubble, Selection, Insertion, Quick, Merge sorting
  • Graph: DFS, BFS, pathfinding algorithms
  • Mathematical: Expression evaluation, number conversion

Problem-Solving Techniques

  • Divide and Conquer: Merge sort, binary search applications
  • Dynamic Programming: Optimization problems
  • Greedy Algorithms: Local optimization strategies
  • Backtracking: Constraint satisfaction problems

Progressive Mastery: Each section builds systematically from fundamental concepts to advanced applications, ensuring comprehensive understanding of both theoretical foundations and practical implementation skills in data structures and algorithms.

About

IT003.P13

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages