You are viewing a single thread.
View all comments View context
15 points

int coerces to double automatically, without explicit casting

permalink
report
parent
reply
18 points

The CPU has to do real work to convert between float and int types. Returning an int type would just be giving the CPU extra work to do for no reason

permalink
report
parent
reply
3 points

I’m learning so much from this thread and I don’t even use Java

permalink
report
parent
reply

Programmer Humor

!programmer_humor@programming.dev

Create post

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

  • Keep content in english
  • No advertisements
  • Posts must be related to programming or programmer topics

Community stats

  • 7.1K

    Monthly active users

  • 953

    Posts

  • 36K

    Comments