<p>So, lets say I have a number 123456.  123456 % 97 = 72.  How can I determine what two digits need to be added to the end of 123456 such that the new number % 97 = 1?  Note--it must always be two digits.</p>

<p>For example, 123456<strong>76</strong> % 97 = 1.  In this case, I need to add the digits "76" to the end of the number.</p>

<p>(This is for IBAN number calculation.)</p>

```
```
x = 123456

x = x * 100
newX = x + 1 + 97 - (x % 97)
```
```
Edit: put the 100 in the wrong place