• Home
  • Random
  • Log in
  • Settings
  • About Safer nicotine wiki
  • Disclaimers
Safer nicotine wiki

Template:CENTURY

  • Language
  • Watch
  • View source
Template documentation[view] [edit] [history] [purge]

This template computes the calendar century number for the Gregorian year in parameter. It is different from the astronomical century number (which starts at 0).

Syntax

{{CENTURY|year}}
  • The year must be astronomical (year=1 in 1 AD (Anno Domini), year=0 in 1 BC, year=-1 in 2 BC).

Examples

{{CENTURY|2102}} returns 22
{{CENTURY|2101}} returns 22
{{CENTURY|2100}} returns 21
{{CENTURY|2099}} returns 21
{{CENTURY|2098}} returns 21
{{CENTURY|2002}} returns 21
{{CENTURY|2001}} returns 21
{{CENTURY|2000}} returns 20
{{CENTURY|1999}} returns 20
{{CENTURY|1998}} returns 20
{{CENTURY|1902}} returns 20
{{CENTURY|1901}} returns 20
{{CENTURY|1900}} returns 19
{{CENTURY|1899}} returns 19
{{CENTURY|1898}} returns 19
{{CENTURY|102}} returns 2
{{CENTURY|101}} returns 2
{{CENTURY|100}} returns 1
{{CENTURY|99}} returns 1
{{CENTURY|98}} returns 1
{{CENTURY|2}} returns 1
{{CENTURY|1}} returns 1
{{CENTURY|0}} returns -1
{{CENTURY|-1}} returns -1
{{CENTURY|-2}} returns -1
{{CENTURY|-98}} returns -1
{{CENTURY|-99}} returns -1
{{CENTURY|-100}} returns -2
{{CENTURY|-101}} returns -2
{{CENTURY|-1098}} returns -11
{{CENTURY|-1099}} returns -11
{{CENTURY|-1100}} returns -12
{{CENTURY|-1101}} returns -12

See also

Template:MILLENNIUM
Template:DECADE
Template:YEARCC
Template:YEARYY
Template:MONTHDAYS
Template:IsLeapYear
Template:JULIANDAY
Template:WEEKDAY
Template:CURRENTCENTURY
The above documentation is transcluded from Template:CENTURY/doc. (edit | history)
Editors can experiment in this template's sandbox (create | mirror) and testcases (create) pages.
Add categories to the /doc subpage. Subpages of this template.
Retrieved from "https://safernicotine.wiki/mediawiki/index.php?title=Template:CENTURY&oldid=9847"
Last edited on 4 November 2025, at 04:26
Cookies help us deliver our services. By using our services, you agree to our use of cookies.
More information

Languages

    • বাংলা
    • Dolnoserbski
    • Esperanto
    • Français
    • Hornjoserbsce
    • Seeltersk
    Safer nicotine wiki
    • Creative Commons Attribution-ShareAlike
    • Powered by MediaWiki
    • Monitored by WikiApiary
    • ipv6 ready
    • Powered by Semantic MediaWiki
    • This page was last modified on 4 November 2025, at 04:26. Warning: Page may not contain recent updates.
    • Content is available under Creative Commons Attribution-ShareAlike unless otherwise noted.
    • Privacy policy
    • About Safer nicotine wiki
    • Disclaimers
    • Terms of Use
    • Desktop
    • Data access
    • Developers
    • Statistics
    • Cookie statement