Skip to content

Instantly share code, notes, and snippets.

View trinhtuanvubk's full-sized avatar
🏠
Working from home

Tuan-Vu Trinh trinhtuanvubk

🏠
Working from home
View GitHub Profile
@slowkow
slowkow / needleman-wunsch.py
Last active November 5, 2025 11:49
A simple version of the Needleman-Wunsch algorithm in Python.
#!/usr/bin/env python
"""
The Needleman-Wunsch Algorithm
==============================
This is a dynamic programming algorithm for finding the optimal alignment of
two strings.
Example
-------