Untitled

mail@pastecode.io avatar
unknown
plain_text
a month ago
225 B
1
Indexable
Never
Given a string, find the first non-repeating character in it and return its index. If it doesn't exist, return -1.
Example Input: s = "leetcode"
Example Output: 0 (The first non-repeating character is 'l' and its index is 0.)
Leave a Comment