This summer I am taking a cryptology class and a common task we need to do is finding the modular inverse. When finding the modular inverse for the following I would do it like so:
- 12 mod 23
- 23 mod 101
I just start at 1 and count by the modulo until I find a number that is divisible by the first number. how I do it
This strategy works well when the numbers are small but sometimes it takes forever. Is there a better way I should be doing this? If so can you play do so using these examples given? Thanks and have a great day.