Template:AnA

From Encyclopedia of Scientonomy
Revision as of 19:35, 5 January 2023 by Hakob Barseghyan (talk | contribs) (Created page with "<noinclude> This template is used to add an indefinite article - <code><nowiki>an</nowiki></code> or <code><nowiki>a</nowiki></code> to the word. The template checks the first...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

This template is used to add an indefinite article - an or a to the word. The template checks the first character of the string and does the following:

  • for a, e, i, o, u, it adds an "an"
  • for other letters, adds an "a"
  • for anything else, returns the original string

NOTE: As any "printing" template, it doesn't store any values anywhere, but merely returns a value.

Parameters:

  • ''string'' - any string to which the article should be added.