In a previous lesson,you learned how to make the computer speak.
It turns out, if you put a properly formatted number into your say string, the
computer will pronounce it properly. By "properly formatted," we mean put commas in
after every 3 digits. As an example, put in 1,375 (instead of 1375).
As always, this is done using say, and it'll work with numbers like this:
say("put a number here")
Move the mouse over a dotted box for more information.
Now you try. Use the say to pronounce numbers. Try 1,500, 1,443,555,332, or 3,979,422,455,332,998.
Type your code here:
See your results here:
Show a friend, family member, or teacher what you've done!
Here is a share link to your code:
Does your code work? Want to run it on your iPhone?
Here's your code:
Use [Control]-[C] (Windows) or [⌘]-[C] (MacOS) to copy your code.
Paste it using [Control]-[V] (Windows) or [⌘]-[V] (MacOS) into
this page
Then click the "Use on iPhone" button that you'll see.