【Leetcode】Isomorphic Strings
来源:互联网 发布:淘宝互刷群可靠吗 编辑:程序博客网 时间:2024/05/02 18:50
题目链接:https://leetcode.com/problems/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.
All occurrences of a character must be replaced with another character while preserving the order of characters. No two characters may map to the same character but a character may map to itself.
For example,
Given "egg"
, "add"
, return true.
Given "foo"
, "bar"
, return false.
Given "paper"
, "title"
, return true.
Note:
You may assume both s and t have the same length.
思路:
用HashMap存储字符之间映射关系,要注意是双向映射即a映射到b,b也要映射到a,用hashmap要判断两次。
算法:
1 0
- LeetCode 205 - Isomorphic Strings
- [LeetCode] Isomorphic Strings
- Isomorphic Strings Leetcode JAVA
- [LeetCode] Isomorphic Strings
- [LeetCode 205]Isomorphic Strings
- LeetCode 205-Isomorphic Strings
- leetcode Isomorphic Strings
- leetcode(c++) Isomorphic Strings
- leetcode--Isomorphic Strings
- [LeetCode]Isomorphic Strings
- LeetCode OJ Isomorphic Strings
- leetcode 205: Isomorphic Strings
- leetcode 205 Isomorphic Strings
- [leetcode] Isomorphic Strings
- 【leetcode】Isomorphic Strings
- [leetcode]Isomorphic Strings
- [LeetCode]Isomorphic Strings
- leetcode--Isomorphic Strings
- 《大数据精准挖掘》保险电销应用—寻找目标客户
- emacs 安装ecb插件
- 致高考结束的你们
- 【Leetcode】Word Pattern
- 定义常量 const 和 #define 区别1
- 【Leetcode】Isomorphic Strings
- 定义常量 const 和 #define 区别2
- CodeForces 680A&680B&680C&680D Round#356
- 《剑指offer》:[23]从上往下打印二叉树
- 2016.6总结 回43 ZRT的6.31??!!
- 解决引入JS中文乱码问题
- Ubuntu常遇问题及解决方案
- c点滴
- 感知器学习笔记