Predloga:Odstotek
| Uporablja Lua: |
Uporaba
{{Odstotek | numerator | denominator | decimals to round to (zero or greater) }}
Omejitve
Števila manjša od 0,0001% so izpisna z znanstveno notacijo.
Zgledi
- {{Odstotek | 1 | 3 | 0 }} izpiše 33 %
- {{Odstotek | 1 | 3 | 2 }} izpiše 33.33 %
Uporabijo se lahko negativne vrednosti:
- {{Odstotek | -1 | 3 }} izpiše -33 %
Normal operation is to cut off all decimal zeroes from right in rounding:
- {{Odstotek | 1 | 5 | 2 }} izpiše 20 %
- {{Odstotek | 1111 | 10000 | 4 }} izpiše 11.11 %
Add |pad=yes to always get as many decimals as specified, padding with zeroes where needed:
- {{Odstotek | 1 | 5 | 2 | pad=yes }} izpiše 20,00 %
- {{Odstotek | 1111 | 10000 | 4 | pad=yes }} izpiše 11,1100 %
Third parameter can also be given through |pad=N:
- {{Odstotek | 111 | 1000 | pad=4 }} is same as {{Odstotek | 111 | 1000 | 4 | pad=yes }} and izpiše 11,1000 %
Default denominator is 100:
- {{Odstotek | 20 }} izpiše 20 %
Default precision is zero:
- {{Odstotek | 1 | 3 }} izpiše 33 %
Override the percent symbol
- {{Odstotek | 1 | 3 | % = percent}} izpiše 33 percent
Use a prescribed number of significant figures
- {{Odstotek | 1 | 4000 | sigfig = 3}} izpiše 0,0250 %
Use a prescribed number of significant figures with small percentages
- {{Odstotek | 1 | 40000000 | sigfig = 3}} izpiše 00 %
Use a prescribed number of significant figures with small percentages without scientific notation
- {{Odstotek | 1 | 40000000 | sigfig = 3 | nonscinote = y}} izpiše 00 %
Use a prescribed number of significant figures with large percentages
- {{Odstotek | 40000000 | 2 | sigfig = 3}} izpiše 2,00×109 %
Use a prescribed number of significant figures with large percentages without scientific notation
- {{Odstotek | 40000000 | 2 | sigfig = 3 | nonscinote = y}} izpiše 2,00×109 %
TemplateData
TemplateData za Odstotek
Calculates and displays a percentage value.
| Parameter | Opis | Vrsta | Stanje | |
|---|---|---|---|---|
| Numerator | 1 | The Numerator of the calculated value. The percentage will be calculated as Numerator divided by Demoninator. | Številka | zahtevano |
| Denominator | 2 | The Demoninator of the calculated value. The percentage will be calculated as Numerator divided by Demoninator. Can be left out, in which case 100 will be used as the Demoninator, and the Numerator will be the direct percentage used.
| Številka | predlagano |
| Decimals | 3 | Number of decimals to round to (zero or greater); if pad is not Yes, 0-digits will be cropped from the end.
| Številka | neobvezno |
| Pad / actual number of digits | pad | If yes, use all digits given in Decimals. If a number, pad to that number of decimals. | Niz | neobvezno |
| Significant figures | sigfig | If set to a positive integer, the precision of the returned number will be adjusted to match the requested number of significant figures. | Številka | neobvezno |
| % replacement | % | Replacement for % symbol
| Niz | neobvezno |
Aliasi
Glej tudi
- {{Percent-done}}
- {{Round}}
- {{Significant figures}}
- {{Fractions and ratios}}
- {{Winning percentage}}
- {{Number and percent}}
Content Disclaimer
Informasi ini disarikan dari Wikipedia dan disajikan kembali untuk tujuan edukasi. Konten tersedia di bawah lisensi CC BY-SA 3.0. Kami tidak bertanggung jawab atas ketidakakuratan data yang bersumber dari kontribusi publik tersebut.
- The information displayed on this website is sourced in part or in whole from Wikipedia and has been adapted for the purpose of restating it. We strive to provide accurate and relevant information, however:
- There is no guarantee of absolute accuracy. Wikipedia is an open, collaborative project that can be edited by anyone, so information is subject to change.
- It is not intended to constitute professional advice. The content displayed is for informational and educational purposes only. For important decisions (e.g., medical, legal, or financial), please consult a professional.
- Content copyright. Wikipedia is licensed under the Creative Commons Attribution-ShareAlike License (CC BY-SA). This means that content may be reused with appropriate attribution and shared under a similar license.
- Responsible use. Any risk arising from the use of information from this website is entirely the responsibility of the user.









