What about the people who lived in the Americas or the Pacific 1800 years ago? These people could not have heard of Jesus as missionaries could not have spread any word to them at this time.
(And while I’m about it, Christianity was a whole different thing back then - the Trinity hadn’t been invented, there were multiple sects with very different ideas, what books would be in the New Testament had not been decided, etc etc. People with beliefs of that time would seem highly unorthodox today, and the Christianity of today would be seen as heretical by those in the 3rd century, so who’s going to heaven again?)
Purgatory was invented for the purpose of not sending good people who had not heard of Jesus to hell. But still, these people were denied their chance to get to heaven which seems mighty unfair.
All junior devs should read OCs comment and really think about this.
The issue is whether
is_number()
is performing a semantic language matter or checking whether the text input can be converted by the program to a number type.The former case - the semantic language test - is useful for chat based interactions, analysis of text (and ancient text - I love the cuneiform btw) and similar. In this mode, some applications don’t even have to be able to convert the text into eg binary (a ‘gazillion’ of something is quantifying it, but vaguely)
The latter case (validating input) is useful where the input is controlled and users are supposed to enter numbers using a limited part of a standard keyboard. Clay tablets and triangular sticks are strictly excluded from this interface.
Another example might be
is_address()
. Which of these are addresses? ‘10 Downing Street, London’, ‘193.168.1.1’, ‘Gettysberg’, ‘Sir/Madam’.To me this highlights that code is a lot less reusable between different projects/apps than it at first appears.