⚡️ Tryprepforge
Backend Engineer Senior programming

Implement a function to determine if two strings are one edit away from being the same string. An edit can be an insertion, deletion, or replacement of a character. Please implement the following function: ```python def isOneEditAway(first: str, second: str) -> bool: ``` ### Constraints: - 0 <= first.length, second.length <= 100 - Both strings consist of lowercase English letters. ### Example 1: Input: first = "pale", second = "ple" Output: true ### Example 2: Input: first = "pales", second = "pal" Output: false

Suggested Answer

Practice More Questions Like This

Generate unlimited interview questions with structured answers, code runner, and AI-powered walkthroughs.

No credit card required

More Backend Engineer Interview Prep

Link copied to clipboard