一、有限状态机(Finite State Machine,FSM)是表示有限个状态及在这些状态之间的转移和动作等行为的数学模型,在计算机领域有着广泛的应用。FSM一个常见的应用就是用来负责Parser复杂的数据结构,比如解释URI协议&#x…
Given a string, find the first non-repeating character in it and return it’s index. If it doesn’t exist, return -1.
Examples:
s “leetcode” return 0.
s “loveleetcode”, return 2. Note: You may assume the string contain only lowercase letters.
…