Given two strings s and t, determine if they are isomorphic.
Two strings are isomorphic if the characters in s can be replaced to get t, with a one-to-one mapping between characters. Every occurrence of a character in s must map to the same character in t, and no two different characters in s may map to the same character in t.
The mapping must work in both directions: each character in s maps to exactly one character in t, and each character in t is mapped to by exactly one character in s.
s = "egg", t = "add"trues = "foo", t = "bar"falses = "paper", t = "title"true1 <= s.length <= 5 * 10^4s.length == t.lengths and t consist of printable ASCII charactersRun your code to see results
Use Cmd+Enter to run