Discuss Scratch
- Discussion Forums
- » Bugs and Glitches
- » Ceiling of 5.0 = 6. Ceiling of 5 = 5.
- SuperdoggyJr
- Scratcher
42 posts
Ceiling of 5.0 = 6. Ceiling of 5 = 5.
Both of these statements ring true for me.
Anyway, just in case it's just one browser or computer, I noticed this behaviour with these specs:
My browser / operating system: Windows 7, Microsoft Internet Explorer 11.0, Flash 12.0 (release 0)
<([ceiling v] of (5)) = [5]>I know it has to do with computational error due to how computers store decimals… but still, seems like a bit of awkward behaviour that could probably be fixed easily.
<([ceiling v] of (5.0)) = [6]>
Anyway, just in case it's just one browser or computer, I noticed this behaviour with these specs:
My browser / operating system: Windows 7, Microsoft Internet Explorer 11.0, Flash 12.0 (release 0)
- DadOfMrLog
- Scratcher
1000+ posts
Ceiling of 5.0 = 6. Ceiling of 5 = 5.
It's because there's no such thing as zero point zero for some strange reason. Zero point zero is no longer zero… **
(And, no, it shouldn't be ‘rounding error’ since computers should store floating-point zero exactly.)
Try this (and weep)…
EDIT: should mention this project also demonstrates the bug: http://scratch.mit.edu/projects/36859670/
** Perhaps this reaction may be more appropriate: 0.0
(And, no, it shouldn't be ‘rounding error’ since computers should store floating-point zero exactly.)
Try this (and weep)…
say ( (0.0) - (0) )S'pose this should be reported as a bug, so I've done that: http://github.com/LLK/scratch-flash/issues/582
EDIT: should mention this project also demonstrates the bug: http://scratch.mit.edu/projects/36859670/
** Perhaps this reaction may be more appropriate: 0.0
Last edited by DadOfMrLog (Jan. 7, 2015 15:45:01)
Alternate account: TheLogFather –– HowTos and useful custom blocks (see studio). Examples below…
- String manipulation - - - X to power of Y - - - Clone point to clone - Detect New Scratcher - Speed tests studio -
- st19_galla
- Scratcher
1000+ posts
Ceiling of 5.0 = 6. Ceiling of 5 = 5.
–Added to the Official Bugs and Glitches List–
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ | I'ᗰ ᔕT19_Gᗩᒪᒪᗩ! | ᑎEᗯ TO ᔕᑕᖇᗩTᑕᕼ? ᐯIᔕIT TᕼE ᗯEᒪᑕOᗰIᑎG ᑕOᗰᗰITTEE! |
⠀⠀⠀⠀⠀⠀⠀| ᗩ GᑌIᗪE TO (ᑎOT) ᑎEᑕᖇOᑭOᔕTIᑎG! | ᐯIᔕIT TᕼE ᔕᑕᖇᗩTᑕᕼ ᗯIKI ᖴOᖇ ᗩᑎY ᑫᑌEᔕTIOᑎᔕ! |
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ This signature is looking a bit… вℓυє, why don't we add a bit of яє∂?
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ Đ₳Ɽ₦, ₳₦ ɆVłⱠ ₭Ʉ₥QɄ₳₮ ł₴ Ɇ₳₮ł₦₲ ₥Ɏ ₴ł₲₦₳₮ɄⱤɆ!
- SuperdoggyJr
- Scratcher
42 posts
Ceiling of 5.0 = 6. Ceiling of 5 = 5.
**Lol… xD not quite what I was expecting. also if you try 1.0 - 0, the error appears to become larger? IDK… It's because there's no such thing as zero point zero for some strange reason. Zero point zero is no longer zero…
(And, no, it shouldn't be ‘rounding error’ since computers should store floating-point zero exactly.)
Try this (and weep)…say ( (0.0) - (0) )S'pose this should be reported as a bug, so I've done that: http://github.com/LLK/scratch-flash/issues/582
EDIT: should mention this project also demonstrates the bug: http://scratch.mit.edu/projects/36859670/
** Perhaps this reaction may be more appropriate: 0.0
Thanks for the bug report. ;P
- ev3commander
- Scratcher
500+ posts
Ceiling of 5.0 = 6. Ceiling of 5 = 5.
ceiling 21 = 21, and ceiling 21.0= 22. Weird.
My browser / operating system: Windows 7, Chrome 35.0.1916.153, Flash 14.0 (release 0)
My browser / operating system: Windows 7, Chrome 35.0.1916.153, Flash 14.0 (release 0)
- SuperSonicmario
- Scratcher
100+ posts
Ceiling of 5.0 = 6. Ceiling of 5 = 5.
Floating-point error:
An issue when computers cannot calculate large numbers precisely.
Example, 1,000,000,000 becomes 1,000,001,211.
This annoys me in my project with many blocks. The block with the issue that annoys me is in Sensing.
An issue when computers cannot calculate large numbers precisely.
Example, 1,000,000,000 becomes 1,000,001,211.
This annoys me in my project with many blocks. The block with the issue that annoys me is in Sensing.
- 3sal2
- Scratcher
100+ posts
Ceiling of 5.0 = 6. Ceiling of 5 = 5.
Which one? Is it the Floating-point error:
An issue when computers cannot calculate large numbers precisely.
Example, 1,000,000,000 becomes 1,000,001,211.
This annoys me in my project with many blocks. The block with the issue that annoys me is in Sensing.
(distance to [Sprite1 v])
block?
- grokblah
- Scratcher
100+ posts
Ceiling of 5.0 = 6. Ceiling of 5 = 5.
I just created a pull-request with a fix for this ( https://github.com/LLK/scratch-flash/pull/698 ). Hopefully we can get it merged soon if it looks good to other developers. Thanks for all of the information about this issue!
- OxySean
- Scratcher
26 posts
Ceiling of 5.0 = 6. Ceiling of 5 = 5.
They fixed the bug in this update: https://scratch.mit.edu/discuss/topic/107954/
I just tried the ceiling glitch and the subtraction glitches. The ceiling of 5 is 5, the ceiling of 5.0 is 5, 0.0 minus 0 is 0, and 1.0 minus 0 is 1.
I just tried the ceiling glitch and the subtraction glitches. The ceiling of 5 is 5, the ceiling of 5.0 is 5, 0.0 minus 0 is 0, and 1.0 minus 0 is 1.
Yang-Yang2 :: control
OxySean :: sensing
-Carbonate- ::extension
- Harakou
- Scratcher
1000+ posts
Ceiling of 5.0 = 6. Ceiling of 5 = 5.
https://scratch.mit.edu/discuss/topic/107954/Yep! Closing as fixed. Please report this thread to reopen it if the issue pops up again. They fixed the bug in this update:
I just tried the ceiling glitch and the subtraction glitches. The ceiling of 5 is 5, the ceiling of 5.0 is 5, 0.0 minus 0 is 0, and 1.0 minus 0 is 1.
- Discussion Forums
- » Bugs and Glitches
- » Ceiling of 5.0 = 6. Ceiling of 5 = 5.