← 返回 amazon 的题目列表First Non-Repeating Character in a String
类型:online_judge
Given a string, find the first non-repeating character in it and return its index. If it does not exist, return -1.
Example:
Input: "leetcode"
Output: 0
Input: "loveleetcode"
Output: 2
Example
Input
"leetcode"
Output
0