2021年4月4日星期日

How to map the alphabetic match after n positions

I would like to check if there is anyone that can generate a formula that I can match the alphabetic order after 20 positions, for example , "a" matches "u", "b" matches "v", and "k" matches back to "e". which is simply shift 20 positions.

I can easily do this by double the alphabetic string but it definitely can be done in a mathematically. I know for a - f , it is n + 20, and for "f - z" it is n - 6. just wondering if there is any generalised formula for this situation?

Cheers

https://stackoverflow.com/questions/66948035/how-to-map-the-alphabetic-match-after-n-positions April 05, 2021 at 11:52AM

没有评论:

发表评论