How to map character to numeric position in java?

前端 未结 7 1971
忘了有多久
忘了有多久 2020-11-30 06:26

E.g.

  • input: [\'A\', \'Z\', \'F\', \'D\', ...]
  • output: [0, 25, 5, 3, ...]

In C I\'d just subtract the char from \'A\', but I don\'t seem

7条回答
提交回复
热议问题