시간 제한 | 메모리 제한 | 제출 | 정답 | 맞힌 사람 | 정답 비율 |
---|---|---|---|---|---|
1 초 | 512 MB | 78 | 69 | 66 | 91.667% |
Organising programming contests is a lot of work. One of the many tasks, some say the most important one, is to arrange reimbursement for the jury (and other volunteers) for their travel to the contest. In order to obtain their reimbursements, the jury members provide (among other things) their International Bank Account Numbers (IBANs), uniquely identifying their bank accounts. If they make a typo when writing their IBAN, the reimbursement cannot be sent, but fortunately an IBAN contains two check digits that can be used to mitigate such errors. Let us help the contest organisers by verifying that a provided IBAN is correct, so that the reimbursements are not delayed more than necessary.
For those of you who do not know, an IBAN is a string consisting of between $15$ and $34$ upper-case letters and digits. To validate a given IBAN, the following amazing procedure is used.
For example, consider the IBAN "NL20INGB0001234567
". After performing the first step we get the string "INGB0001234567NL20
", and then after replacing letters with digits we get the number $182316110001234567232120$. The remainder of this number modulo $97$ equals $1$, so this was indeed a valid IBAN.
The input consists of:
If the given IBAN is valid, output "correct
". Otherwise, output "incorrect
".
NL20INGB0001234567
correct
NL20ASNB0001234567
incorrect
ICPC > Regionals > Europe > Northwestern European Regional Contest > NWERC 2019 PA번