Using "Generation", what is the generation of the Sri Lanka National ID number? Can be identified. Generation can only be identified in valid ID numbers.
- Description:
Using "Generation", what is the generation of the Sri Lanka National ID number? Can be identified. Generation can only be identified in valid ID numbers.
- Source:
Classes
Methods
(inner) determiningTheGenerationFromChar(nationalIdentityCardNumber) → {1|2}
- Description:
When coming from first-generation IDs to second-generation, the last letter "V/X" used to determine whether the first-generation ID is eligible to vote or not can be used to identify the generation. Generation 1 as 1 and Generation 2 as 2.
- Source:
Parameters:
Name | Type | Description |
---|---|---|
nationalIdentityCardNumber |
String |
Returns:
- Type
- 1 | 2
(inner) determiningTheGenerationFromLength(nationalIdentityCardNumber) → {1|2}
- Description:
The increase in the number of characters in the ID number from the first generation to the second generation is used to identify the generation. Generation 1 as 1 and Generation 2 as 2.
- Source:
Parameters:
Name | Type | Description |
---|---|---|
nationalIdentityCardNumber |
String |
Returns:
- Type
- 1 | 2
(inner) witchGeneration(nationalIdentityCardNumber) → {"1"|"2"}
- Description:
From the first generation to the second generation, the removal of the characters "V/X" and the increase in the number of characters are both used to determine the generation of the National ID number. Generation 1 as "1" and Generation 2 as "2".
- Source:
Parameters:
Name | Type | Description |
---|---|---|
nationalIdentityCardNumber |
String |
Returns:
- Type
- "1" | "2"