The students will learn to read the Quorum Programming Language's "Library" documentation and will use actions that accept parameters in order to complete a series of challenges which require them to make use of the Quorum Programming Language's "Library" documentation to learn new drawing commands. Many of these commands will require the use of parameters. The final challenge asks the students to design a personal monogram making use of the commands that they learned in the lesson.
Students will be able to:
The "Library" is a reference guide which catalogs and explains the functionality of a programming language in Quorum Programming Language. If a programmer develops the practice of referencing a "Library," he or she can make full use of that functionality without undergoing the tedium of memorizing every detail of the language. In today's lesson, the students will need to read through the "Quorum Standard Library" in order to find and understand new commands for moving the turtle to draw different patterns of shapes on the screen. The students should not necessarily understand every command in the "Quorum Standard Library" in detail, but they should be familiar with referencing the "Quorum Standard Library" as a standard part of the process of writing a program. This will also be the first time that they are given access to drawing functions that take parameters.
So far in this unit the students have been exploring programming by drawing turtle art with only a few commands. It will probably not surprise them to learn that there are many more commands included in most programming languages. In fact, most programming languages include hundreds if not thousands of commands. The Quorum Programming Language includes an extensive number of actions that make it possible for the students to not only work on the Quorum Turtle module, but also to create 2D and 3D games, mobile apps, commercial programs, and even control robots. Possibility is limitless as far as they, "the programmers," have imagination and creativity.
Do they think programmers memorize all of the commands in a programming language? If not, how is anyone ever able to use an entire programming language?
Visit the Quorum Standard Libraries and explore it by following the directions below. In it, the students will see the documents where they can find lists of actions with general descriptions and an example for each action. If the students are not familiar with this language - and most of them should not be at this point - the majority of the information in the documents would not make any sense to them. That is OK at this point. The purpose of this activity is to provide them with a chance to learn how to navigate in the Quorum Standard Libraries. If they get the flow of the navigation, have them try to find the library class for the documentation of the the Quorum Turtle Module.
The image below shows the Quorum Language web site. The Quorum Standard Libraries at the top level is a vast list of classes that contains actions available for the programmers.
Today the students are going to see how some functions can accept input, such as a number, to more exactly control the turtle's behavior and learning the term parameter. For example, a student can write RepeatMoveForward(3) to move the turtle 3 block with this single call of an action.
Place the turtle at position (0, 0), then use the action RepeatMoveForward(11) to move the turtle forward 11 steps. Try it and see what happens. The number you wrote in the parenthesis at the end of this action RepeatMoveForward() is called "parameter" in the Quorum Programming Language. It gives the programmer an option to input how he or she wants the simple command to be modified on execution. The parameter could be one number, several numbers, text, or even combination of all the above, each separate by comma in the parenthesis.
Your goal for this challenge is to try to find the dimensions of movable area for the turtle in this module.
The students will soon find out that the turtle does not go any further than a certain point. If the students check their console output area at that point, they will see the message "Couldn't move up (or down/right/left)."
As we noted in the previous lessons, the Quorum Turtle Module consists of 121 dots arranged in eleven rows and eleven columns. The parameter "x" represents the column number, and "y" represents the row number.
So the SetStartingCoordinates(x, y) actually accepts two parameters. Note that the first row and first column have x = 0 and y = 0 for their coordinates, respectively, and the final (eleventh) row and column have x = 10 and y = 10, respectively. You can try to start the turtle at different positions in the IDE below.
The level progression for today's lesson includes many important vocabulary words. While these levels attempt to introduce these words in the context of using them, take a moment at the conclusion of the class to review the words covered and ensure that the students are comfortable using them.
It is said that actions with parameters generalize the behavior of a more specific command. Explain what this sentence means to you using the difference between turnLeft() and turnLeft(angle).
Ask the students to use the commands learned today to draw a picture. Ask them to challenge one of their classmates to recreate the picture. If the classmate was able to recreate this picture, ask the students to compare and contrast on how the methods that they both used.