This repository contains solutions to four algorithmic problems implemented in Python as part of the Data Structures course assignments.
The project focuses on string manipulation, interval processing, combinatorial search, and sequence analysis.
A custom string expression evaluator supporting special operators:
+: character interleaving*: character repetition**: string repetition
Example:
Input:
"ab"**2+"c"*2
Output:
aaccbbaabb
Concepts used:
- String manipulation
- Expression parsing
- Sequential evaluation
Given multiple time intervals, determine the longest interval during which the maximum number of events overlap.
Example:
Input:
04:30-06:00 05:20-06:45 07:00-08:30
Output:
05:20-06:00
Concepts used:
- Sweep Line Algorithm
- Event sorting
- Interval processing
A 4×4 board contains players and corresponding goals.
The objective is to determine the maximum number of successful player-to-goal matches while respecting movement constraints and blocking rules.
Concepts used:
- Grid traversal
- Simulation
- Permutation generation
- Combinatorial search
Given two strings, determine the minimum number of deletions required from a selected segment of the first string so that the second string becomes a subsequence.
Concepts used:
- Greedy matching
- String scanning
- Subsequence analysis
.
├── problem1.py
├── problem2.py
├── problem3.py
├── problem4.py
└── README.md
- Python 3
- Standard Library
This assignment was designed to strengthen practical skills in:
- Algorithm design
- Complexity analysis
- String processing
- Search techniques
- Data manipulation
Data Structures Course
Spring 2025
University Assignment