Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Lesson 9: conditionals

  • Loading branch information...
commit ab7149255f7732cb0687f6ada32eb60f1e6bc7ea 1 parent 8db1e82
Aaron Harnly authored
Showing with 82 additions and 35 deletions.
  1. +79 −0 2013-09-24.html
  2. +3 −35 index.html
79 2013-09-24.html
View
@@ -0,0 +1,79 @@
+
+<html><head>
+ <title>Computer Science</title>
+ <style type="text/css">
+ body {
+ background-color: #1B3E59;
+ }
+ h2 {
+ color: #AB7300;
+ }
+ body {
+ color: #494A4A;
+ }
+ a, a:hover, a:visited {
+ color: #0000ee;
+ }
+ .section {
+ padding: 1em;
+ background-color: #E1DFE3;
+ width: 30em;
+ margin-left: auto;
+ margin-right: auto;
+ margin-bottom: 1em;
+ }
+ .screenshot {
+ width: 400px;
+ }
+ .block { width: 300px; }
+ </style>
+ </head>
+ <body>
+ <div class="section">
+ <h2>Do Now</h2>
+ <p><a target="donow" href="https://docs.google.com/forms/d/1iwC9Iibm3lOPP9TjYyTaCxcLaqv9njj5W2X9MVjOL4o/viewform">Do Now</a></p>
+ </div>
+ <div class="section">
+ <h2>Snap Setup</h2>
+ <p>Remember, your Snap! username is: ywls-{firstname}{lastinitial}. For example, Alicia Smith would be ywls-alicias.</p>
+ <p>Your password is 'teals2013'.</p>
+ <p>Before doing anything else, log in.</p>
+ <p><a target="snap" href="http://snap.berkeley.edu/run">Start Snap!</a></p>
+ </div>
+ <div class="section">
+ <h2>Loops: N-Sided Polygon</h2>
+ <p>Your challenge: Create a program that</p>
+ <ul>
+ <li>Asks you how many sides you want in your polygon</li>
+ <li>Sets a variable for the number of sides</li>
+ <li>Sets another variable with the angle to turn at each side</li>
+ <li>Uses a loop to draw each side of the polygon, and turn to prepare to draw the next side</li>
+ <li><em>Make sure</em> to initialize your program with "clear" and "go to 0, 0" blocks so you
+ have a clean stage each time.</li>
+ </ul>
+ <p>Here is an example of running the N-Sided Polygon program and choosing 4 sides:</p>
+ <p><img src="http://i.imgur.com/uHnTWKT.png" class="screenshot">
+ <img src="http://i.imgur.com/W8Fd5j1.png" class="screenshot"></p>
+
+ <p>Here I run it again, but choose 8 sides:</p>
+ <p><img src="http://i.imgur.com/DwwhFrC.png" class="screenshot">
+ <img src="http://i.imgur.com/EMsrQeO.png" class="screenshot"></p>
+
+ <p>This is my program (made blurry so you don't just copy it!):</p>
+ <p><img src="http://i.imgur.com/FBShXMA.png" class="screenshot"></p>
+ </div>
+ <div class="section">
+ <h2>Conditionals</h2>
+ <p>Your challenge: Create a program that counts up from 1 to 10</p>
+ <p>Use:
+ <img src="http://i.imgur.com/88cPi4s.png" class="block">
+ <img src="http://i.imgur.com/soEEjFj.png" class="block">
+ </p>
+ <p>Output the numbers using: </p>
+ <img src="http://i.imgur.com/ynwobQY.png" class="block">
+ </div>
+
+
+</body></html>
+
+
38 index.html
View
@@ -30,8 +30,10 @@
</head>
<body>
<div class="section">
+ <h1>Computer Science, 2013-09-25</h1>
<h2>Do Now</h2>
- <p><a target="donow" href="https://docs.google.com/forms/d/1iwC9Iibm3lOPP9TjYyTaCxcLaqv9njj5W2X9MVjOL4o/viewform">Do Now</a></p>
+ <p>Click to <a target="donow"
+ href="https://docs.google.com/forms/d/1J9_JaQuAqltGUI30xPriQqWU2Q8SCNtuHQyYNE9_ncE/viewform">Do Now</a></p>
</div>
<div class="section">
<h2>Snap Setup</h2>
@@ -40,40 +42,6 @@
<p>Before doing anything else, log in.</p>
<p><a target="snap" href="http://snap.berkeley.edu/run">Start Snap!</a></p>
</div>
- <div class="section">
- <h2>Loops: N-Sided Polygon</h2>
- <p>Your challenge: Create a program that</p>
- <ul>
- <li>Asks you how many sides you want in your polygon</li>
- <li>Sets a variable for the number of sides</li>
- <li>Sets another variable with the angle to turn at each side</li>
- <li>Uses a loop to draw each side of the polygon, and turn to prepare to draw the next side</li>
- <li><em>Make sure</em> to initialize your program with "clear" and "go to 0, 0" blocks so you
- have a clean stage each time.</li>
- </ul>
- <p>Here is an example of running the N-Sided Polygon program and choosing 4 sides:</p>
- <p><img src="http://i.imgur.com/uHnTWKT.png" class="screenshot">
- <img src="http://i.imgur.com/W8Fd5j1.png" class="screenshot"></p>
-
- <p>Here I run it again, but choose 8 sides:</p>
- <p><img src="http://i.imgur.com/DwwhFrC.png" class="screenshot">
- <img src="http://i.imgur.com/EMsrQeO.png" class="screenshot"></p>
-
- <p>This is my program (made blurry so you don't just copy it!):</p>
- <p><img src="http://i.imgur.com/FBShXMA.png" class="screenshot"></p>
- </div>
- <div class="section">
- <h2>Conditionals</h2>
- <p>Your challenge: Create a program that counts up from 1 to 10</p>
- <p>Use:
- <img src="http://i.imgur.com/88cPi4s.png" class="block">
- <img src="http://i.imgur.com/soEEjFj.png" class="block">
- </p>
- <p>Output the numbers using: </p>
- <img src="http://i.imgur.com/ynwobQY.png" class="block">
- </div>
-
-
</body></html>
Please sign in to comment.
Something went wrong with that request. Please try again.