ਫਰਮਾ:Wins-losses-pct in table
(ਫਰਮਾ:WinLossPct ਤੋਂ ਮੋੜਿਆ ਗਿਆ)
Description
ਸੋਧੋThis template produces three wikitable columns that represent wins, losses and a winning percentage as follows:
<wins> || <losses> || <winning percentage>
where wins
comes from parameter 1 to this template, losses
comes from parameter 2 and <winning percentage>
is automatically computed based on parameters 1 and 2. Winning percentage is calculated as a three-decimal place value between .000 and 1.000.[1]
Examples
ਸੋਧੋ{{WinLossPct|3|0}}
produces 3 || 0 || 1.000{{WinLossPct|6|9}}
produces 6 || 9 || .400{{WinLossPct|0|5}}
produces 0 || 5 || .000{{WinLossPct|0|0}}
produces 0 || 0 || –
{| class=wikitable ! Team !! Wins !! Losses !! Percent |- | Bluebirds || {{WinLossPct|6|9}} |- | Blackbirds || {{WinLossPct|4|3}} |}
produces:
Team | Wins | Losses | Percent |
---|---|---|---|
Bluebirds | 6 | 9 | .400 |
Blackbirds | 4 | 3 | .571 |
See also
ਸੋਧੋNotes
ਸੋਧੋ- ↑ This is what is colloquially referred to as a "percentage" in sports, though it is not mathematically accurate. 6 wins and 6 losses produces ".500", not "50%".