ebooksgratis.com

See also ebooksgratis.com: no banners, no cookies, totally FREE.

CLASSICISTRANIERI HOME PAGE - YOUTUBE CHANNEL
Privacy Policy Cookie Policy Terms and Conditions
Template:Mod/doc - Wikipedia, the free encyclopedia

Template:Mod/doc

From Wikipedia, the free encyclopedia

This is a documentation subpage for Template:Mod (see that page for the template itself).
It contains usage information, categories and other content that is not part of the original template page.

Implements the mathematical modulo operator. The returned result is always of the same sign as the modulus or nul, and its absolute value is lower than the absolute value of the modulus. However, this template returns 0 if the modulus is nul (this template should never return a division by zero error). This template is not the same as the mod operator in the #expr parser function.

Usage:
{{mod|dividend|modulus}}
Computes the modulo dynamically.
{{subst:mod|dividend|modulus|subst=subst:}}
Substitute the template invokation by its computed value when saving an article wiki source.
Examples with positive integer modulus:
  • {{mod|12|10}} = 2.
  • {{mod|10.1|10}} = 0.1.
  • {{mod|10|10}} = 0.
  • {{mod|2|10}} = 2.
  • {{mod|0|10}} = 0.
  • {{mod|-2|10}} = 8.
  • {{mod|-10|10}} = 0.
  • {{mod|-10.1|10}} = 9.9.
  • {{mod|-12|10}} = 8.
Examples with negative integer modulus:
  • {{mod|12|-10}} = -8.
  • {{mod|10.1|-10}} = -9.9.
  • {{mod|10|-10}} = 0.
  • {{mod|2|-10}} = -8.
  • {{mod|0|-10}} = 0.
  • {{mod|-2|-10}} = -2.
  • {{mod|-10|-10}} = 0.
  • {{mod|-10.1|-10}} = -0.1.
  • {{mod|-12|-10}} = -2.
Examples with positive non integer modulus:
  • {{mod|21.5|10.5}} = 0.5.
  • {{mod|21.1|10.5}} = 0.1.
  • {{mod|21|10.5}} = 0.
  • {{mod|20.9|10.5}} = 10.4.
  • {{mod|11|10.5}} = 0.5.
  • {{mod|10.6|10.5}} = 0.1.
  • {{mod|10.5|10.5}} = 0.
  • {{mod|10.1|10.5}} = 10.1.
  • {{mod|10|10.5}} = 10.
  • {{mod|2|10.5}} = 2.
  • {{mod|0|10.5}} = 0.
  • {{mod|-2|10.5}} = 8.5.
  • {{mod|-10|10.5}} = 0.5.
  • {{mod|-10.1|10.5}} = 0.4.
  • {{mod|-10.5|10.5}} = 0.
  • {{mod|-10.6|10.5}} = 10.4.
  • {{mod|-11|10.5}} = 10.
  • {{mod|-20.9|10.5}} = 0.1.
  • {{mod|-21|10.5}} = 0.
  • {{mod|-21.1|10.5}} = 10.4.
  • {{mod|-21.5|10.5}} = 10.
Examples with nul modulus:
  • {{mod|2|0}} = 0.
  • {{mod|0|0}} = 0.
  • {{mod|-2|0}} = 0.
See also:


aa - ab - af - ak - als - am - an - ang - ar - arc - as - ast - av - ay - az - ba - bar - bat_smg - bcl - be - be_x_old - bg - bh - bi - bm - bn - bo - bpy - br - bs - bug - bxr - ca - cbk_zam - cdo - ce - ceb - ch - cho - chr - chy - co - cr - crh - cs - csb - cu - cv - cy - da - de - diq - dsb - dv - dz - ee - el - eml - en - eo - es - et - eu - ext - fa - ff - fi - fiu_vro - fj - fo - fr - frp - fur - fy - ga - gan - gd - gl - glk - gn - got - gu - gv - ha - hak - haw - he - hi - hif - ho - hr - hsb - ht - hu - hy - hz - ia - id - ie - ig - ii - ik - ilo - io - is - it - iu - ja - jbo - jv - ka - kaa - kab - kg - ki - kj - kk - kl - km - kn - ko - kr - ks - ksh - ku - kv - kw - ky - la - lad - lb - lbe - lg - li - lij - lmo - ln - lo - lt - lv - map_bms - mdf - mg - mh - mi - mk - ml - mn - mo - mr - mt - mus - my - myv - mzn - na - nah - nap - nds - nds_nl - ne - new - ng - nl - nn - no - nov - nrm - nv - ny - oc - om - or - os - pa - pag - pam - pap - pdc - pi - pih - pl - pms - ps - pt - qu - quality - rm - rmy - rn - ro - roa_rup - roa_tara - ru - rw - sa - sah - sc - scn - sco - sd - se - sg - sh - si - simple - sk - sl - sm - sn - so - sr - srn - ss - st - stq - su - sv - sw - szl - ta - te - tet - tg - th - ti - tk - tl - tlh - tn - to - tpi - tr - ts - tt - tum - tw - ty - udm - ug - uk - ur - uz - ve - vec - vi - vls - vo - wa - war - wo - wuu - xal - xh - yi - yo - za - zea - zh - zh_classical - zh_min_nan - zh_yue - zu -