select pg_typeof(9999999999999999.0);
-- numeric
select 9999999999999999.0::double precision
- 9999999999999998.0::double precision;
-- 2
More interesting perhaps, is mixing up `real` (aka float32) with `numeric`: select 9999999999999999.0::real - 9999999999999998.0;
-- 272564226 (?! can anyone explain?)
select 9999999999999999.0::real;
-- 10000000300000000
Wat julia> 9999999999999999.0 - 9999999999999998.0
2.0
julia> -9.999999999999999 + 9.999999999999998
0.0
That being said, Claude Code produces the best code I've seen from an AI coding agent, and the subscriptions are a steal.