Use decimal numbers (BigDecimal in Java) instead.
Use decimal numbers (BigDecimal in Java) instead.
@stefanofago.bsky.social breaks down when double, BigDecimal, or fixed-point is the right call, and the production traps that quietly undo each one.
#java #deepdive
@stefanofago.bsky.social breaks down when double, BigDecimal, or fixed-point is the right call, and the production traps that quietly undo each one.
#java #deepdive
foojay.io/today/double...
#Java #Programming
foojay.io/today/double...
#Java #Programming
TY Ken Fogel
https://buff.ly/4fJMxqW
TY Ken Fogel
https://buff.ly/4fJMxqW
Arbitrary-precision integer and decimal arithmetic for the ez-php ecosystem — immutable BigInteger and BigDecimal value objects backed by bcmath (gmp optional)
🔗 https://github.com/ez-php/bignum
Arbitrary-precision integer and decimal arithmetic for the ez-php ecosystem — immutable BigInteger and BigDecimal value objects backed by bcmath (gmp optional)
🔗 https://github.com/ez-php/bignum
Arbitrary-precision integer and decimal arithmetic for the ez-php ecosystem — immutable BigInteger and BigDecimal value objects backed by bcmath (gmp optional)
🔗 https://github.com/ez-php/bignum
Arbitrary-precision integer and decimal arithmetic for the ez-php ecosystem — immutable BigInteger and BigDecimal value objects backed by bcmath (gmp optional)
🔗 https://github.com/ez-php/bignum
https://tech-blog.rakus.co.jp/entry/20240705/bigdecimal
https://tech-blog.rakus.co.jp/entry/20240705/bigdecimal
stackoverflow.com/questions/14...
stackoverflow.com/questions/14...
Quando acertava o código, não conseguia explicar ao mesmo tempo em que digitava.
Pensamentos são mais rápidos que falas — talvez porque pensamos em conceitos, não em palavras.
Quando acertava o código, não conseguia explicar ao mesmo tempo em que digitava.
Pensamentos são mais rápidos que falas — talvez porque pensamos em conceitos, não em palavras.
bsky.app/profile/mvsa...
But that's not an option for BigDecimal.
bsky.app/profile/mvsa...
https://magicmarcy.de/datentypen-in-java-ohne-stolperfallen
#DAtentypen #Java #Stolperfallen #2038 #Overflow #int #Integer #String #float #double #BigDecimal #Wertebereiche #Programming
https://magicmarcy.de/datentypen-in-java-ohne-stolperfallen
#DAtentypen #Java #Stolperfallen #2038 #Overflow #int #Integer #String #float #double #BigDecimal #Wertebereiche #Programming
jshell> new BigDecimal("123")
$194 ==> 123
jshell> new BigDecimal("١٢٣")
$195 ==> 123
jshell> new BigDecimal("123")
$194 ==> 123
jshell> new BigDecimal("١٢٣")
$195 ==> 123