Grokking Graph Algorithms for Coding Interviews
Ask Author
Back to course home

0% completed

Minimum Genetic Mutation (medium)
Table of Contents

Contents are not accessible

Contents are not accessible

Contents are not accessible

Contents are not accessible

Contents are not accessible

Problem Statement

You have a gene sequence represented by an 8-character string, containing only 'A', 'C', 'G', or 'T' characters. To change from one gene sequence to another, you can mutate one character at a time.

For example, "AAAAACCC" --> "AAAACCCC" is one mutation.

Each intermediate sequence must be a valid gene in the provided list (bank).

The gene bank bank records all the valid gene mutations. A gene must be in bank to make it a valid gene string.

Given the two gene strings startGene and endGene and the gene `bank

.....

.....

.....

Like the course? Get enrolled and start learning!

Table of Contents

Contents are not accessible

Contents are not accessible

Contents are not accessible

Contents are not accessible

Contents are not accessible