This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2010-12-15 04:31:32

Shadowed1
Scratcher
Registered: 2010-01-19
Posts: 100+

Glitch with the number 2.53

For some reason, whenever you enter '2.53' or '-2.53' into any text block, about 13 0's and and a 2 comes up after the original number.
It's just a weird glitch...
http://scratch.mit.edu/projects/Shadowed1/1481044 - Photo of glitch

Discovered by me.

Last edited by Shadowed1 (2010-12-15 04:32:30)


*Insert some witty, funny or sarcastic comment here*

Offline

 

#2 2010-12-15 05:21:17

mathematics
Scratcher
Registered: 2009-03-01
Posts: 1000+

Re: Glitch with the number 2.53

This glitch hasn't been mentioned for ages...  tongue  I've already forgotten about it.

This glitch also happens for these number: -3.14159265, -1.93, -1.91, -1.89, 1.89, 1.91, 1.93, 3.14159265
(Source: Four glitches on Scratch 1.4)

Last edited by mathematics (2010-12-15 05:22:42)

Offline

 

#3 2010-12-15 22:30:19

Jonathanpb
Scratcher
Registered: 2008-07-25
Posts: 1000+

Re: Glitch with the number 2.53

O_o WOOOOAH THAT HAPPENSSSSS!!!??? WWWHHHHHAAAAAAAATTT!!!!!????? *checks* WWWWWOOOOOOOAAAAAAAAHHHHHH


"Human beings... must have action; and they will make it if they cannot find it.
-Charlotte Brontë

Offline

 

#4 2010-12-17 22:20:21

Shadowed1
Scratcher
Registered: 2010-01-19
Posts: 100+

Re: Glitch with the number 2.53

I know.
It's weird...


*Insert some witty, funny or sarcastic comment here*

Offline

 

#5 2010-12-17 22:28:01

Harakou
Community Moderator
Registered: 2009-10-11
Posts: 1000+

Re: Glitch with the number 2.53

That is strange...
*head explodes*


http://www.blocks.scratchr.org/API.php?action=random&return=image&link1=http://i.imgur.com/OZn2RD3.png&link2=http://i.imgur.com/duzaGTB.png&link3=http://i.imgur.com/CrDGvvZ.png&link4=http://i.imgur.com/POEpQyZ.png&link5=http://i.imgur.com/ZKJF8ac.png

Offline

 

#6 2010-12-17 22:35:51

hdarken
Scratcher
Registered: 2008-06-26
Posts: 1000+

Re: Glitch with the number 2.53

How odd.


http://i.imgur.com/VskBk.png
http://i.imgur.com/tgxVZ.jpg

Offline

 

#7 2010-12-17 22:42:09

ihaveamac
Scratcher
Registered: 2007-09-22
Posts: 1000+

Re: Glitch with the number 2.53

If I remember from an older post, computers are not so absolute with numbers. You could see 1234.5678 on an application, but under the hood it could be 1234.56780000000000000000000000000000000004. The app just removes the extra numbers.


~ihaveamac - visit ihaveamac.net

Offline

 

#8 2010-12-18 07:14:19

ScratchReallyROCKS
Scratcher
Registered: 2009-04-22
Posts: 1000+

Re: Glitch with the number 2.53

It's just computer number inaccuracy. I don't fully understand it, but I know it's not specifically a Scratch glitch. It even happens in other programming languages.

EDIT: outposted  sad

Last edited by ScratchReallyROCKS (2010-12-18 07:15:12)


http://imageshack.us/a/img694/3806/sigmad.png

Offline

 

#9 2010-12-22 20:09:19

Shadowed1
Scratcher
Registered: 2010-01-19
Posts: 100+

Re: Glitch with the number 2.53

I just found that if you type 2.53 into a 'Looks' or 'Sensing' block, it's fine. But all the other ones do a really good job of adding on 13 0's and then a 2.


*Insert some witty, funny or sarcastic comment here*

Offline

 

#10 2010-12-23 01:06:33

mathematics
Scratcher
Registered: 2009-03-01
Posts: 1000+

Re: Glitch with the number 2.53

Shadowed1 wrote:

I just found that if you type 2.53 into a 'Looks' or 'Sensing' block, it's fine. But all the other ones do a really good job of adding on 13 0's and then a 2.

It's because Scratch treats texts in rectangular holes as 'strings' but texts in rounded holes as 'numbers'.

Offline

 

#11 2010-12-23 14:22:40

Hitechcomputergeek
Scratcher
Registered: 2010-11-21
Posts: 47

Re: Glitch with the number 2.53

I just realized that it only happens where it can't be a string.

Last edited by Hitechcomputergeek (2013-04-21 19:34:59)


http://scratch.mit.edu/static/projects/Hitechcomputergeek/1687140_sm.png

Offline

 

#12 2010-12-24 10:41:55

TheSuccessor
Scratcher
Registered: 2010-04-23
Posts: 1000+

Re: Glitch with the number 2.53

ScratchReallyROCKS wrote:

It's just computer number inaccuracy. I don't fully understand it, but I know it's not specifically a Scratch glitch. It even happens in other programming languages.

It's because computers store numbers in binary. Integers can be translated perfectly, but decimals are different. ½ in binary = 0.1, and ¼ = 0.01, 3/8 = 0.011 and 5/8 = 0.101. Mathematical people might begin to see the pattern now. 1/3 in binary = 0.0101 recurring. This is converted back from 0.0101010101 (or however many digits your computer stores it to) as 1/4 + 1/16 + 1/64 + 1/256 + 1/1024. This comes to 0.333007812.
Your computer will do it more accurately as it stores the binary number to many more decimal places. Some numbers though, are particularly difficult to store in binary, and so, when the computer rounds the number, once it has been converted back, incorrectly, these errors creep in. [/longBoringLectureOnMaths]


/* No comment */

Offline

 

Board footer