Get unique integer value from string

前端 未结 5 1766
我在风中等你
我在风中等你 2021-02-07 06:34

I have different unique strings in the same format. The string looks like this axf25!j&809>-11~dc and I want to get unique integer value from this string.

5条回答
  •  忘了有多久
    2021-02-07 06:51

    You could just use String.hashCode() (e.g. mystring.hashCode()) to give you a degree of uniqueness but you must ensure you can handle collisions.

提交回复
热议问题