September 29, 2026

Algorithms in Python and Java

Implemented data structures and algorithms in Python and Java to study correctness and computational cost.

Learning project
Role
Software engineer
Published
September 2026
Focus
Learning project
Engineer
Saaim Abdullah
Algorithms in Python and Java system overview

The problem

Knowing a library call is different from understanding the work it performs. These repositories make the data structure, algorithm and reasoning visible, from basic searching to graph paths and dynamic programming.

Organization

The Python collection is organized by topic, covering arrays, graphs, trees, linked lists, stacks, queues, recursion, tries and dynamic programming. The separate DSA repository contains Java exercises, including collections, sorting, linked lists, trees and object oriented programming examples. This is a collection of independent programs rather than a deployed service. Inputs and example calls live near the implementations, which makes individual techniques easier to study without setting up an application stack.

A concrete implementation

The Python Dijkstra implementation represents a graph with an adjacency dictionary of weighted neighbours. A heap selects the next candidate with the smallest known distance. The algorithm ignores stale heap entries and pushes an updated candidate when a shorter path is found. The same file explores a binary maze using a queue and a minimum effort grid path using a heap. Seeing these alongside each other highlights that the objective determines the state and update rule. The number of steps, sum of weights, and maximum edge difference define different problems.

Engineering decisions and next steps

Standalone scripts make experiments approachable, but repeated helpers and examples that print results do not provide a uniform regression suite. Some files contain alternative or unfinished approaches. This collection is presented as engineering practice, not a production algorithm package or a claim of comprehensive test coverage. The next improvement would be parameterized tests for edge cases and explicit algorithm preconditions, including edge weights of zero or greater for Dijkstra. Packaging reusable structures separately would reduce duplication while preserving the worked examples.

Source code

Algorithms in Python and Java architecture diagram 1

More to explore

Let’s talk

I like working through complex problems with people who care about the details. Have a product to build, an engineering role, or an interesting challenge? Let’s start a conversation.

A little note

SaaimOpen to full-time roles, contract work, and conversations about things worth building.

ϟ 1
Contact