use this project if you want to get the checksum of any Singapore vehicle. how to use -> 1. prefix currently works on vehicle numbers starting with F, G, P, Q, S, W, X and Y. prefixes FA_, FE_, FU_, GA_, GE_, GU_, PA_, PE_, PU, SA, SE_, SHE, SHY, SKY, SLY, SP, SU_, WA_, WE, WP and YE_, as well as letters I and O (to prevent confusion with numbers 1 and 0 respectively) are disallowed. 2. then, enter a 4-digit number between 0001 and 9999. leading zeros must be included if the original number is less than 4 digits. 3. after entering a 6 or 7-digit vehicle number, the checksum will be shown in front of the car number you had entered. for example SG4003 will have the checksum D, and SBA1234 will have the checksum G. how the checksum works -> the checksum letter is calculated by converting the letters into numbers, i.e., where A=1 and Z=26, potentially giving seven individual numbers from each registration plate. however, only two letters of the prefix are used in the checksum. for a three-letter prefix, only the last two letters are used; for a two-letter prefix, both letters are used; for a single letter prefix, the single letter corresponds to the second position, with the first position as 0. for numerals less than four digits, leading zeroes are added in front as placeholders, for example "1" is "0001". SBS9889 would therefore give 2, 19, 9, 8, 8 and 9 (note that "S" is discarded); E12 would give 0, 5, 0, 0, 1 and 2, and SG2017 would give 19, 7, 2, 0, 1, 7. each individual number is then multiplied by 6 respective numbers (9, 4, 5, 4, 3, 2), added up together, then modulo by 19. the result corresponds to one of the 19 letters used (A, Z, Y, X, U, T, S, R, P, M, L, K, J, H, G, E, D, C, B), where 0=A, 1=Z, 2=Y and so on. in the case of SBS9889, the final letter is a U; for E23, the final letter should be a H, and SG2017 final letter should be a C. letters F, I, N, O, Q, V and W are not used as checksum letters.
please heart and fave this project, more math-computing projects coming soon :)