Skip to content

Latest commit

 

History

History
17 lines (12 loc) · 364 Bytes

File metadata and controls

17 lines (12 loc) · 364 Bytes

Problem 6: Edit Distance

Problem Statement

Given two strings, find the minimum number of operations (insert, delete, replace) to convert one to the other.

Input Format

  • Two strings word1 and word2.

Output Format

  • An integer.

Constraints

  • 0 <= len(word1), len(word2) <= 500

Example

Input: word1="horse", word2="ros"
Output: 3