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

#1 2012-02-11 11:12:44

king12314
New Scratcher
Registered: 2012-02-11
Posts: 5

help with a check

so hi,
i got a problem with my script i want to make a check if the number is divisible by 2 without remainder. and if yes he will send a message.
i tried to do it but i stuck with the remainder..
thanks  smile

Offline

 

#2 2012-02-11 11:23:19

TRocket
Scratcher
Registered: 2009-08-18
Posts: 1000+

Re: help with a check

if <((number) mod (2)) = (0)>
 say[no remainder]
else
 say[remainder]
should do the trick! :0

Last edited by TRocket (2012-02-11 11:25:46)


http://i.imgur.com/1QqnHxQ.png

Offline

 

#3 2012-02-11 13:01:58

king12314
New Scratcher
Registered: 2012-02-11
Posts: 5

Re: help with a check

wow big thanks  smile

Offline

 

#4 2012-02-11 13:07:59

RedRocker227
Scratcher
Registered: 2011-10-26
Posts: 1000+

Re: help with a check

if <((Number) mod [2]) = [0]>
  set [Remainder v] to [No]
else
  set [Remainder v] to [Yes]


Why

Offline

 

Board footer