Template:MONTHNUMBER: Difference between revisions
Jump to navigation
Jump to search
Content added Content deleted
mNo edit summary |
m (negative numbers are nightmares for computing ceils and modulos!) |
||
Line 1: | Line 1: | ||
<includeonly>{{#if:{{{1|}}}|{{#ifexpr:{{{1|}}}<0|{{#ifexpr:(({{{1|}}})round 0)!=({{{1|}}})|{{#expr: |
<includeonly>{{#if:{{{1|}}}|{{#ifexpr:{{{1|}}}<0|{{#ifexpr:(({{{1|}}})round 0)!=({{{1|}}})|{{#expr:12-(((0.5-({{{1|}}}))round 0)mod 12)}}|{{#expr:12-(((11.5-({{{1|}}}))round 0)mod 12)}}}}|{{#expr:(((10.5+{{{1|}}})round 0)mod 12)+1}}}}|Missing required parameter 1=''month''!}}</includeonly><noinclude>{{Template documentation}} |
||
12-(((0.5-({{{1|}}}))round 0)mod 12) |
|||
}}|{{#expr: |
|||
12-(((11.5-({{{1|}}}))round 0)mod 12) |
|||
}}}}|{{#expr:(((10.5+{{{1|}}})round 0)mod 12)+1}}}}|Missing required parameter 1=''month''!}}</includeonly><noinclude>{{Template documentation}} |
|||
This template returns the cyclic integer month number (between 1 and 12) of the month whose real number is in parameter. |
This template returns the cyclic integer month number (between 1 and 12) of the month whose real number is in parameter. |
||
; Syntax<nowiki>:</nowiki> |
; Syntax<nowiki>:</nowiki> |