Referenced from lesson Applying Functions
Type this line of code into the interactions area and hit "Enter": triangle(50, "solid", "red")
1) |
What is the name of this function? |
|
2) |
What did the expression evaluate to? |
|
3) |
How many arguments does |
|
4) |
What does the |
Catching Bugs
The following lines of code are all BUGGY! Can you spot the mistake? If you have time, type in the buggy code and see if Pyret agrees with you!
5) |
|
|
Can you spot the mistake? |
||
What error message does Pyret return? |
||
6) |
|
|
Can you spot the mistake? |
||
What error message does Pyret return? |
||
7) |
|
|
Can you spot the mistake? |
||
What error message does Pyret return? |
||
8) |
|
|
Can you spot the mistake? |
||
What error message does Pyret return? |
||
9) |
|
|
Can you spot the mistake? |
||
What error message does Pyret return? |
These materials were developed partly through support of the National Science Foundation, (awards 1042210, 1535276, 1648684, and 1738598). Bootstrap:Data Science by Emmanuel Schanzer, Nancy Pfenning, Emma Youndtsmith, Jennifer Poole, Shriram Krishnamurthi, Joe Politz, Ben Lerner, Flannery Denny, and Dorai Sitaram with help from Eric Allatta and Joy Straub is licensed under a Creative Commons 4.0 Unported License. Based on a work at www.BootstrapWorld.org. Permissions beyond the scope of this license may be available by contacting schanzer@BootstrapWorld.org.