Quite a few programming languages use the keyword END to mark the end of a structured statement or the end of a procedure declaration etc. Is this word to be read as a noun or as a verb (in imperative)? In some human languages other than English the noun form of this word is different from the verb form such as SLUT and SLUTA in Swedish.
Asked
Active
Viewed 39 times
-3
-
2In the context of a block scope, it would be a verb. It really depends on the usage. It can be used as both in English. – Mr. Polywhirl Mar 14 '23 at 16:46
-
What is the material difference in interpretation, for language design, between the verb and the noun? – High Performance Mark Mar 14 '23 at 16:48
-
@HighPerformanceMark There would be no difference in interpretation but if the programming language was to use keywords in say Swedish the designer would have to choose between *SLUT* and *SLUTA*, or use both in different contexts. – August Karlstrom Mar 14 '23 at 16:50
-
@Mr.Polywhirl It's a lucky coincidence then (and a nice property of the English language) that the same keyword END can be used in both declarations and statements without sounding wrong. – August Karlstrom Mar 14 '23 at 17:03
-
So in Swedish and, I suppose, many other languages you'd want to match the noun which means 'end' with the noun that means 'beginning', or the verb which means 'end' with the verb which means 'begin'. I'm still struggling to understand why you don't just choose one interpretation and get on with it. – High Performance Mark Mar 14 '23 at 17:18
-
@HighPerformanceMark I think Mr. Polywhirl has the answer to my question in the first comment -- END is either read as a noun (in declarations) or as a verb (in statements). My conclusion then was that if the keyword language hadn't been English, two different words may have been needed to make it "grammatically correct." – August Karlstrom Mar 14 '23 at 19:42
1 Answers
0
Many other keywords are ambiguous and could be nouns or verbs.
Languages that use end
often use it with other verbs like:
- begin ... end
- do ... end
- repeat ... end
So you could imagine that end
is a verb. But in English, it doesn't make a real difference. Keywords are often chosen because they are short. You may introduce a value with a verb like let
or not a verb (var
, const
).
Endings / declensions are often avoided for convenience and to keep the keywords short (code doesn't try to be grammatically correct).

Laurent
- 2,951
- 16
- 19
-
We also have type or variable declarations containing `RECORD ... END` where it's more natural to read END as a noun. – August Karlstrom Mar 15 '23 at 10:34