← Back to companies
[ OK ] Loaded —
[ INFO ]
$ cd
$ ls -lt
01
02
03
04
05
$ ls -lt
01
02
03
04
05
user@intervues:~/$
Given two strings s and t, return true if they are both exactly one edit distance apart, otherwise return false.
A string s is said to be one edit distance apart from a string t if you can transform s into t by performing exactly one of the following operations:
s to get t.s to get t.s with a different character to get t.
Equal strings are not one edit distance apart — the count of edits must be exactly one.