Project Folders
Teacher Resources
Student Resources
How Do I?
Site Map
Our Team

MWForum Message [Date Index] [Threads] [Authors] [Attachments] [Subscribe]

[Thread Prev] [Thread Next]

To: mwforum@xxxxxxxxxxxxxxxxxxxxxxxxxxxx
Subject: Re: red or black
From: "Daniel Ajoy" <da.ajoy@xxxxxxxxx>
Date: Sun, 26 Jul 2009 23:13:25 -0500
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed;

On Sun, 26 Jul 2009 21:53:39 -0500, <askanexpert@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> 

> from: Charles Cobbold Melbourne Australia
> date: Sun Jul 26 20:53:39 2009
> platform: PC
> version: MicroWorlds Ex
> I am trying to get microworlds EX to count the number of incidences of red 
> and black from a text box.  How do I do this?
> to prove1
> text1, cleartext
> repeat 100 [text1, print pick [red Black]]
> show count [red]
> show count [Black]
> end
> I am wanting to prove to students that pick is random.
> Charles

This should work (project attached)

to prove1
talkto "red cleartext
talkto "black cleartext

repeat 100 [
talkto pick [red black]
print "chip

show textcount "red
show textcount "black

OpenWorld Learning

Attachment: red_black.mwx
Description: application/mwx-plugin

  • Previous by thread: MIA, Ask an Expert
  • Next by thread: MIA, Ask an Expert

  • To save an attachment to your computer, PC users should right-click (Mac users, click and hold the mouse button) on the link and then choose 'save target as' from the pop-up menu. A window will then pop up in which you can choose a location for the file.

    © copyright 2001 - 2008