Your Challenge
We intentionally hid errors in the code below. Please pick your favourite language(s) and send us the errors per language you chose.
The first one who spots all bugs (in at least one language) will receive an amazon voucher worth 50 EUR.
Context
An International Securities Identification Number (ISIN) is a unique international identifier for a financial security such as a stock or bond.
-
Original Task
Write a function or program that takes a string as input, and checks whether it is a valid ISIN.
It is only valid if it has the correct format, and the embedded checksum is correct.
Demonstrate that your code passes the test-cases listed below.
-
Details on the ISIN
The format of an ISIN is as follows:
┌───────────── a 2-character ISO country code (A-Z)
│ ┌─────────── a 9-character security code (A-Z, 0-9)
│ │ ┌── a checksum digit (0-9)
AU0000XVGZA3