Vous êtes sur la page 1sur 2

Name: ______________________________________ M.

Riling

Date: _____________ Alg 1 Programming Lesson 3

How to open the right files!


1. Sign out of the student user of the computer. 2. Sign in, instead, as programming club. The password is cobol. 3. In the top right corner of the screen, there are a bunch of little icons. Click on the one that looks like a light blue open box with a green checkmark. 4. Open these folders: First, the Assignments folder. Inside of that, open the 2012-2013 folder. And finally inside of that, open the Drawing for Alg 1 folder. 5. If there is not a folder with your name on it, please create one now. 6. Go into the folder with the long title, copy the files, and then paste them into your folder. 7. Instead of just opening the files, make sure you do Open with and choose Sublime 2. 8. Even though you need to open them all, you will only do any programming inside the file labeled algebra1Drawing.coffee. 9. To run the program, you will use algebra1Drawing.html. Make sure you Open with firefox.

How to program with shapes!


Our internet drawing canvas has coordinates, but theyre backwards from what were used to.

You will be drawing with two functions. They are named drawCircle and drawRectangle. drawCircle takes four inputs: drawCircle(x-coordinate, y-coordinate, radius, color) drawRectangle takes five inputs: drawRectangle(x-coordinate, y-coordinate, width, height, color)

So if I wrote: drawCircle(20, 40, 5, red) I would get a circle positioned at (20, 40), with a radius of 5 pixels, drawn in red!

So change up the text in the algebra1Drawing.coffee file to include these things and create a beautiful masterpiece.

Vous aimerez peut-être aussi