static boolean isIsomorphic(String s, String t) { if(s.length() != t.length()) return false; int[] s1 = new int[256]; int[] s2 = new int[256]; for(int i = 0; i < s.length(); i++) { if(s1[s.charAt(i)] != s2[t.charAt(i)]) return false; s1[s.charAt(i)] = s2[t.charAt(i)] = i + 1; } return true; } Language used f
-
Notifications
You must be signed in to change notification settings - Fork 0
brave881/easyProblems
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
No description, website, or topics provided.
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published