Isomorphic Strings
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.

30:00

Isomorphic Strings
easy
Topics
Companies

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.

Example 1:
Input: {"s":"egg","t":"add"}
Output: true
Constraints:
  • 1s.length5×1041 \leq s.\text{length} \leq 5 \times 10^4

  • t.length==s.lengtht.\text{length} == s.\text{length}

  • s and t consist of any valid ASCII characters.

Input
arr ={"s":"egg","t":"add"}

Check isomorphic

s
e0g1g2
t
a0d1d2
Variables
VariableValue
segg
tadd
DepthFunction Call
Stack empty
0/4