How to check the Azerbaijan IBAN sample
There is one number on this page: AZ84NABZ00000000137010002944. It is the calculation sample in the Central Bank's rule. It is not an account. No money is sent to it.
The second line is that same sample with only the last digit changed. That is not an account either.
The sample is 28 characters. AZ is the country. The next two digits are the check. Then come four letters. The remaining 20 characters are the account place. If it is short, zeros are written at the front.
The check follows ISO 7064, MOD 97-10. The first four characters move to the end. A letter becomes a number: A is 10, Z is 35. The resulting number is divided by 97. If the remainder is 1, the check digits are right. This does not show that an account exists.
- The code first prints
1. The sample's check digits are right. - The second number is
28. When the last character changes, the remainder is not 1. That is enough to catch a typo. - The four letters in the middle of the sample are part of the sample. They are not an address to pay anyone.
- In your own program you can check your own number. Do not write that number on a page, in a chat, or into the sample.
- Even if the remainder is 1, do not send a large amount without checking with the bank. The form can be right and the account can be closed.
NUMUNE = "AZ84NABZ00000000137010002944"
# Eyni nümunədir. Yalnız son rəqəm dəyişib. Hesab deyil.
POZUK = "AZ84NABZ00000000137010002945"
def qaliq(iban: str) -> int:
metn = iban.replace(" ", "").upper()
if not (len(metn) == 28 and metn.startswith("AZ")):
raise ValueError("format")
kecmis = metn[4:] + metn[:4]
reqem = "".join(str(ord(h) - 55) if h.isalpha() else h for h in kecmis)
return int(reqem) % 97
print(qaliq(NUMUNE))
print(qaliq(POZUK))
- python is not recognized
- The letter ə shows as a square
- Excel breaks the letter ə
- The letter ə becomes a question mark on the page
- Excel opens the CSV as one column
- PowerShell will not run the script
- In JSON the letter ə becomes \u0259
- APK will not install
- What is a parse error?
- The keystore is lost
- The signatures do not match
- Package name error
- The APK file is damaged
- Blocked by Play Protect
- Package appears to be invalid
- Not enough storage
- App not compatible with your device
- An older version will not install
- XAPK will not install
- ödəyici turns into ödÉ™yici
- In C# the letter ə becomes a question mark
- A WhatsApp chat breaks ə in Excel
- In a PDF the letter ə becomes a square
- In MySQL the letter ə becomes a question mark
- In an SMS the letter ə cuts the message to 70 characters
- In Java the letter ə breaks for Excel
- In PHP the letter ə becomes a question mark
- On Android the letter ə becomes a question mark
- A QR code will not take the letter ə
- The ninth digit of a VÖEN cannot be calculated
- Gradle sync failed
- Could not resolve a dependency
- Duplicate class error
- Manifest merger failed
- Dex limit: 65536 methods
- R8: Missing class
- JDK version mismatch
- SDK location not found
- minSdkVersion conflict
- compileSdk is too low
- EAS build: Gradle failure
- expo prebuild error
- Metro: Unable to resolve module
- Hermes: JS error only in release
- White screen in release
- Red screen: cannot reach Metro
- Expo SDK mismatch
- Capacitor sync error
- Capacitor: white screen
- EAS: keystore and credentials error
- Keystore was tampered with / wrong password
- Wrong key alias or password
- Play: signed with the wrong key
- INSTALL_FAILED_UPDATE_INCOMPATIBLE
- INSTALL_FAILED_VERSION_DOWNGRADE
- INSTALL_FAILED_INSUFFICIENT_STORAGE
- INSTALL_FAILED_NO_MATCHING_ABIS
- Parse error (problem parsing the package)
- "App not installed" error
- Installing an AAB file on a phone
- adb: device "unauthorized"
- adb: device not found
- adb server version mismatch
- Activity class does not exist
- Play: targetSdk level too low
- Play: permissions policy rejection
- Play: 64-bit requirement
- Play: versionCode already used
- ClassNotFound / NoSuchMethod crash
- OutOfMemoryError crash
- CLEARTEXT communication not permitted
- SecurityException: permission denied