• Jajcus@kbin.social
    link
    fedilink
    arrow-up
    17
    ·
    1 year ago

    If working with currency use types and formating functions appropriate for currency. Not float.

    • psud@aussie.zone
      link
      fedilink
      arrow-up
      3
      arrow-down
      1
      ·
      edit-2
      1 year ago

      I was recalling a project in perl, which doesn’t have a variety of types. If you add values, you get a scalar, which will be a float if the numbers are not integers.

      I am aware my statement isn’t true in several languages