How to convert an alphanumeric phone number to digits

前端 未结 7 922
臣服心动
臣服心动 2021-01-05 12:50

UPDATE:

The final version of my utility looks like this:

StringBuilder b = new StringBuilder();

for(char c : inLetters.toLowerCase(         


        
相关标签:
7条回答
  • 2021-01-05 13:32

    If you run this 10^9 times in a tight loop and ctrl-break it a few times, my bet is that nearly every time it will be deep in the string class trying to accomplish one of those innocent-looking "+=" operators.

    0 讨论(0)
提交回复
热议问题