Click here to Skip to main content
15,897,518 members

Welcome to the Lounge

   

For discussing anything related to a software developer's life but is not for programming questions. Got a programming question?

The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.

 
GeneralRe: Seeing double, or doublethink Pin
CDP180219-Dec-16 0:04
CDP180219-Dec-16 0:04 
GeneralRe: Seeing double, or doublethink Pin
Chris C-B19-Dec-16 0:24
Chris C-B19-Dec-16 0:24 
GeneralRe: Seeing double, or doublethink Pin
CDP180219-Dec-16 0:35
CDP180219-Dec-16 0:35 
GeneralRe: Seeing double, or doublethink Pin
Chris C-B19-Dec-16 1:03
Chris C-B19-Dec-16 1:03 
GeneralRe: Seeing double, or doublethink Pin
CDP180219-Dec-16 1:06
CDP180219-Dec-16 1:06 
GeneralRe: Seeing double, or doublethink Pin
harold aptroot19-Dec-16 0:06
harold aptroot19-Dec-16 0:06 
GeneralRe: Seeing double, or doublethink Pin
Chris C-B19-Dec-16 0:29
Chris C-B19-Dec-16 0:29 
GeneralRe: Seeing double, or doublethink Pin
harold aptroot19-Dec-16 1:18
harold aptroot19-Dec-16 1:18 
Well, I don't get it. While there are differences between truncating division and division followed by floor, none of them seem like an immediately obvious culprit. Then, without context it's hard to tell.
  • VB's \ will first round its inputs to integers, then divide them with truncation. The initial rounding makes it different, and it will do weird things if the input is outside of the range of an integer, but then you would have a total BS result and you don't.
  • division-followed-by-floor means the division first rounds (not to an integer, but to the nearest double) and then it goes down instead of towards zero (so for negative results it's usually different by 1).
And then there's the usual "floating point stuff that runs on x86 will probably use x87 and its weird 80bit floats" thing that likes to mess things up unpredictably.
GeneralRe: Seeing double, or doublethink Pin
OriginalGriff19-Dec-16 0:07
mveOriginalGriff19-Dec-16 0:07 
GeneralRe: Seeing double, or doublethink Pin
CDP180219-Dec-16 0:10
CDP180219-Dec-16 0:10 
GeneralRe: Seeing double, or doublethink Pin
OriginalGriff19-Dec-16 0:16
mveOriginalGriff19-Dec-16 0:16 
GeneralRe: Seeing double, or doublethink Pin
  Forogar  19-Dec-16 3:27
professional  Forogar  19-Dec-16 3:27 
GeneralRe: Seeing double, or doublethink Pin
Jochen Arndt19-Dec-16 0:33
professionalJochen Arndt19-Dec-16 0:33 
GeneralRe: Seeing double, or doublethink Pin
Chris C-B19-Dec-16 0:51
Chris C-B19-Dec-16 0:51 
GeneralRe: Seeing double, or doublethink Pin
Jochen Arndt19-Dec-16 0:59
professionalJochen Arndt19-Dec-16 0:59 
GeneralRe: Seeing double, or doublethink Pin
Chris C-B19-Dec-16 1:21
Chris C-B19-Dec-16 1:21 
GeneralRe: Seeing double, or doublethink Pin
Jochen Arndt19-Dec-16 1:27
professionalJochen Arndt19-Dec-16 1:27 
GeneralRe: Seeing double, or doublethink Pin
harold aptroot19-Dec-16 1:21
harold aptroot19-Dec-16 1:21 
GeneralWSO CCC OTD 2016-12-19 Pin
OriginalGriff18-Dec-16 22:02
mveOriginalGriff18-Dec-16 22:02 
GeneralRe: WSO CCC OTD 2016-12-19 Pin
pkfox18-Dec-16 22:24
professionalpkfox18-Dec-16 22:24 
GeneralRe: WSO CCC OTD 2016-12-19 - we have a winner! Pin
OriginalGriff18-Dec-16 22:29
mveOriginalGriff18-Dec-16 22:29 
GeneralMQOTD Pin
V.18-Dec-16 21:31
professionalV.18-Dec-16 21:31 
GeneralRe: MQOTD Pin
Kornfeld Eliyahu Peter18-Dec-16 21:55
professionalKornfeld Eliyahu Peter18-Dec-16 21:55 
GeneralRe: MQOTD Pin
OriginalGriff18-Dec-16 22:21
mveOriginalGriff18-Dec-16 22:21 
GeneralRe: MQOTD Pin
Kornfeld Eliyahu Peter18-Dec-16 22:27
professionalKornfeld Eliyahu Peter18-Dec-16 22:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Straw Poll

Were you affected by the geomagnetic storms this past weekend?
Communication disruptions, electrified pipes, random unexplained blue-screens in Windows - the list of effects is terrifying.
  Results   98 votes