Floor - floor(16.9 * 100) = 1689 ? |
Floor - floor(16.9 * 100) = 1689 ? |
24.10.2016, 21:27:52
Post
#1
|
|
Grupa: Zarejestrowani Postów: 155 Pomógł: 0 Dołączył: 22.06.2010 Ostrzeżenie: (0%) |
Jak w temacie: http://sandbox.onlinephpfunctions.com/code...7e5d74db5e26f24
Wytłumaczy ktoś? |
|
|
24.10.2016, 22:51:46
Post
#2
|
|
Grupa: Moderatorzy Postów: 4 069 Pomógł: 497 Dołączył: 11.05.2007 Skąd: Warszawa |
|
|
|
25.10.2016, 11:59:57
Post
#3
|
|
Grupa: Zarejestrowani Postów: 155 Pomógł: 0 Dołączył: 22.06.2010 Ostrzeżenie: (0%) |
Cytat This can lead to confusing results: for example, floor((0.1+0.7)*10) will usually return 7 instead of the expected 8, since the internal representation will be something like 7.9999999999999991118.... Dzięki, temat do zamknięcia. |
|
|
Wersja Lo-Fi | Aktualny czas: 25.04.2024 - 22:13 |