Tuesday, September 30, 2008

ICA-CP: 9/30/2008

Good morning!

Since we spent last class finishing and signing-off Karel Assignments 1-4, today we will do the assignment from last class. In class, we will derive the algorithm for assignment #5. For homework, you will derive the algorithm for assignment #6. It will be due next class, on Thursday, October 2nd. We will have a test on Thursday, 10/2.

What is on the test? Your test will consist of deriving algorithms from Karel-like assignments (in other words, there will be programming assignments for Karel which I will create). For one of the assignments I designate, you will have to create and run a Karel the robot program -- and show me that it runs in class. This test will be worth 100 points.

If you haven't put your birthday on the board, please do. We need to plan a birthdays celebration!

Friday, September 26, 2008

ica-cp: 9/26/08 - Creating Karel the Robot algorithms

Good morning!

Your Karel the Robot assignments #1-4 are due by the end of class today.
We will spend a few minutes deriving algorithms for your next few Karel the Robot assignments.

From tutorial #9:
Assignment 5: Write a Karel program to move to the corner of 0th Avenue and 0th Street, and turn off, assuming he starts at the corner of 14th Avenue and 0th Street, is facing west, and that obstacles may be in the way. The obstacles are walls that block 0th Street but do not extend east, north, or west. To get around an obstacle, Karel may turn right, move to 1st Street, turn left, move to the next lower numbered avenue, turn left, move again to get back to 0th Street, and turn right to continue his journey. Keep in mind that 1st Street may have some walls too, but they don't connect to the obstacles on 1st Street. (Hint: use an iterate and an if/else.)

ICA-CP - Birthdays

8/9 Isabel
8/20 Genevieve
8/28 Kiara (Chi Chi)
9/13 Ashley
10/21 Laura
10/4 Luisa
11/9 Eileen
11/19 Francesca
11/26 Thalia
12/18 Christiana
1/14 Tiara
1/29 Patricia
2/9 Lindsay
2/20 Alex
3/25 Paola
4/4 Tiffany
5/5 Victoria (Tui)
6/6 Dujour
7/16 Jeanette
12/8 Ana
1/8 Aoife
8/17 Jeznia
9/10 Karyn
6/9 Erica
11/30 Leighton
9/6 Roniesha

Wednesday, September 24, 2008

ICA-CP: 9/24/08

Greetings!

Here are a few reminders.
1) Please be sure to read the blog entry on algorithms from today's class.
2) Karel the Robot Assignments #1-4 are due on Friday, 9/26/08.
3) Next week on Thursday, 10/2/08, we will have a quiz on algorithms.
4) Please write your birthday on the board so we can plan a celebration.

ICA-CP: 9/24/08 - More on algorithms

How do we turn a set of instructions into an algorithm?

State: Turning a set of tasks or instructions into an algorithm involves understanding the goal of the task, indentifying the start conditions for completing the task, and then breaking the task down into a series of sequential steps.

Elaborate: First we need to understand the activity for which we need to write a program. If we need to make a pizza, we would not want to create an algorithm for making a milkshake. We also need to identify what we have been given as a starting set of conditions -- and perhaps asking more questions if we do not have enough information. So, if we want to make a milkshake, we should have all the ingedients available to make a milkshake. In other words, we don't use cheese, pizza sauce, and pepperoni to make a milkshake. Once we have a clear picture of the task (step 1) and a clear set of starting conditions (step 2), then we start creating a set of steps to accomplish the task.

eXemplify: Here are the examples for the first four Karel the Robot assignments.
Assignment #1:
Step 1) Goal: Move Karel from Street 0, Avenue 14 to Street 0, Avenue 0.
Step 2) Start condition: Karel faces West
Step 3) Algorithm: Move Karel 14 steps.

Assignment #2:
Step 1) Goal: Move Karel from Street 0, Avenue 14 to Street 0, Avenue 0.
Step 2) Start condition: Karel faces South
Step 3) Algorithm: (Step 3a) Turn Karel left 3 times. Then, (Step 3b) move Karel 14 steps.

Assignment #3:
Step 1) Goal: Move Karel from Street 0, Avenue 14 to Street 0, Avenue 0.
Step 2) Start condition: Karel faces any of North, South,, West, or East.
Step 3) Algorithm: (Step 3a) Figure out which direction Karel is facing. (Step 3b) Turn Karel left enough times to face West. (Step 3c) Move Karel 14 steps.

Assignment #4:
Step 1) Goal: Move Karel from Street 0, Avenue 14 to Street 0, Avenue 0 picking up all the beepers along Street 0. (Please note: This means we do not pick up beepers that are in any other row than Street 0.)
Step 2) Start condition: Karel faces West
Step 3) Algorithm: (Step 3a) Check if Karel is next to a beeper. (Step 3b) If Karel is next to a beeper, then pick it up. (Step 3c) Move 1 step. (Step 4c) Repeat the series of steps 3a, 3b, and 3c fourteen times.

One note: Only do what is needed to accomplish the task or activity. For example, if the activity is to make a chocolate dessert pizza, do not add extras (like anchovies) to the pizza.

Illustrate:
Creating an algorithm is like making S'mores (understanding the task), identifying the start conditions (ingredients available? heat source = campfire, oven, or microwave?), and then identifying the steps needed to actually "cook" something to eat. I don't want to make brownies if I'm supposed to make S'mores (understaning the task). I may have a campfire instead of a microwave (starting conditions). I don't melt the marshmellow and chocoate until I've put them between two graham crackers (creating the steps).

Monday, September 22, 2008

ICA-CP: 9/22/08

Good morning!

Today, we continue with Karel the Robot. By now, everyone should have the Karel worlds and the Karel tutorials on their computers. So, since we are a bit behind on Karel and to keep us focused, today is a !Internet day. In other words, work on Karel the Robot and nothing else today (the Internet is turned off).

ICA-CP: Question of the Week - Due 9/26/08

Background:
Karel the Robot is a computer simulation of a real robot. For a definition of a simulation, see the Wikipedia definition at this link: http://en.wikipedia.org/wiki/Computer_model Computer simulations allow users (who may be doctors, lawyers, the disabled, a researcher, or any one of us) to perform tasks that may be too dangerous or too expensive, to try alternatives before choosing the best course of action (a doctor simulating a brain operation, for example), or to learn a new skill (like driving or flying a jet plane), or design a roller coaster. Even more realistic are simulations that attempt to use a Virtual Reality (see Wikipedia for a definition: http://en.wikipedia.org/wiki/Virtual_reality). Here are some computer simulation links:

Driving simulator: http://www.stisimdrive.com/?gclid=CMK4583h75UCFQ8QagodYCUFew

Flight Simulator: http://www.baseops.net/flightsimulators/

Brain Surgery Simulator: http://content.karger.com/ProdukteDB/produkte.asp?Doi=100260

Virtual Reality Field Trips: http://www.sciencedaily.com/videos/2005/1011-virtual_reality_field_trips.htm

Movies like the The Lawnmover Man and The Matrix are about computer simulations. The Ninentendo Wii uses simulations. You might want to do some more Internet reasearch by yourself on simulations.

Questions of the Week:
As computers become more sophisticated, simulations will be more and more complex. What kinds of computer simulations, other than Karel the Robot, do you use? How do you see computer simulations being used now and in the future in sports, in the classroom, in medicine, or in any other facet of daily life? Do you think that some individuals might escape into Virtual Reality and never come back to reality? (There have been science fiction stories and movies written wbout this topic.)

Thursday, September 18, 2008

ICA-CP: 9/18/08 - More Karel

Good afternoon!

We are continuing with Karel the Robot. Be sure to check Powerschool today, and give me any blogs due to me before the end of 7th period!!!

Tuesday, September 16, 2008

ICA-CP: 9/12/08 - Continue with Karel the Robot

Good morning!

We continue onward with Karel the Robot. Today, do tutorials number 5, 6, and 7. Do assignment number 3 using the Assignment3 World.kw file.

Thursday, September 11, 2008

Question of the Week - Due 9/19/08

Background:
Beware of online threats! Online threats include phony web sites where hackers try to pry credit card numbers and other identity theft information from you. (Trying to get information from you is known as "phishing", pronounced like "fishing.) Poisoned web sites are the fasted growing Internet threat, and try to control your computer from afar by adding malicious code to a legitimate web site or by creating a totally "evil" web site. Bogus pop-up windows are another threat.Bogus pop-up windows appear on your screen and lead one to believe that they are delivering real messages from you computer's operating system or software application. Another source of irritation are misleading software applications which appear to be friendly and useful, but in fact leave ads and banners on your screen. Finally, don't catch a virus. A virus can be embedded in seemingly friendly screen savers, background pictures, or other software -- but may cause your computer to slow down and maybe crash.

Below are some links to further information. You may wish to research additional web sites yourself.

Fake and Poisoned Web Sites: http://cybercoyote.org/security/av-web.shtml

Poisoned web poses risk to security: http://technology.newscientist.com/channel/tech/electronic-threats/dn7299

Phishing: http://www.webopedia.com/TERM/p/phishing.html

Phishing: http://www.microsoft.com/protect/yourself/phishing/identify.mspx

Popups: http://www.mvps.org/winhelp2002/nopopups.htm

Question of the Week
How might you protect your identity while reading email or surfing the Internet? What kinds of precautions can you take? What are some of the dangers of downloading screen savers, music, or software from web sites? Are free programs from reputable companies, like Microsoft and Apple, always sage?

ICA-CP: 9/11/08

Good morning!

Please check Powerschool today for your Question of the Week blog grades. If you have a "zero" for the 8/15/08 blog assignment, then I did not get your email with the link to your blog -- or, you didn't put your link in your email -- or, your link didn't work. Some folks are behind in their blogs. Remember, each blog is worth 25 points per week. Amnesty ended last week. So, if you want points for a Question of the Week that was due previously, then there's a penalty of 5 ponts for being late. The maximum points for a late Question of the Week answer in your blog is 20 points since there is a 5 point penalty.

So, today is a catch up day. Work on Karel and finish assignment number two. Catch up on your Questions of the Week. Work on this week's Question of the Week. Finish and turn in your Parrot program. Work on next week's Question of the Week. Print out your picture for me and put it on the board with some of your work (worth 10 points). Then, if you are ALL caught up, you have discretionary time to work on other class work.

Tuesday, September 09, 2008

ICA-CP: 9/9/2008 - Intro to Karel the Robot

Good morning!

Today we start something new. We are meeting Karel the Robot for the first time today. First, some of you mayv have to install Karel. To install Karel, go to the R drive under my name. Look for the folder named, "Karel the Robot Installation Files," and copy the install.exe file to your desktop. After copying it, click on the file to install Karel. Once you have Karel installed, go back to the R drive and copy the folders name "Karel the Robot Tutorial" and "Karel the Robot Assignements" to yourr My Documents folder.

Your assignment for today: Read the first five tutorials first. They are titled: 00-Karel the Robot.pdf, 01-KareTheRobot.pdf, 02-JKarelWorld.pdf, 03-JKarelProggram.pdf, and 04-JKarelPrimitiveCommands.pdf. Do Assignment #1 and Assignment #2. For these two assignments, you will need to use two world files. The world files are named: Assignment1 World.kw and Assignment2 World.kw.

Friday, September 05, 2008

Question of the Week: Due 9/12/08 before 5:00 PM.

Background:
Computers help the disabled in many ways. There are programs and computers to help sight impaired, see this link: http://www.sciencedaily.com/releases/2008/05/080508174310.htm

For those without use of hands and arms, there are ways of controlling computers with one's tongue or eyes. See these links:

http://www.cnn.com/2008/TECH/ptech/08/25/tongue.computing.ap/

http://www.neoseeker.com/news/8672-disabled-peoples-mouths-to-become-virtual-computers/

http://www.ksl.com/index.php?nid=148&sid=939612

Question of the Week:
Do some further research for this question. I have started you with a few ideas above. The question is: How do you see computer technology developing to help the disabled in the next one to five years? If you were an engineer, what new computer gadget would you try to design?

ICA-CP: 9/5/08

Good afternoon!

Today we will start with our quiz. The quiz is worth 25 pounts, We have 30 minutes to finish it. Our first online quiz is at this link: http://www.quia.com/quiz/1474030.html.

After the quiz, we will finish the parrot program by adding a class path to BlueJ, compiling, and running our programs. After your program runs, work on taking and printing our pictures, then putting work on the bulletin board.

Wednesday, September 03, 2008

ICA-CP: 9/3/08 - Parrot Program

Good morning!

This morning, we are learning something new about Java. We will learn how to use Java libraries. First of all, we have this term, code reuseability. Code reusuabilty means we do not have to invent everything we want to do in Java ourselves. If we can find something already written that does what we want, we borrow and modify it. CASE is an example of code reuseability. In our HellowWorld program, we used already written Java code, and just changed it to meet our needs.

In our Parrot program, we said our algorithm is:
1) Open and run the Java program.
2) The user types something at the keyboard which our Java program captures and saves.
3) The keystrokes which the user typed and which our Java program saved are then printed lt on the screen.
4) Steps two and three just capture and print once. We would like our program to allow a user to type and print multiple times. So, we want to repeat steps two and three until the user types the word, "Done."


So, we will start with modifying our HelloWorld program to perform steps one, two, and three. To do that, we need to learn some new Java concepts:
import
string
new
print

How to declare a variable: datatype variable name
How to identify the location of a library in BlueJ

These are the new lines of code we will use:

import TerminalIO.KeyboardReader --> a package and class
KeyboardReader getTyping = new KeyboardReader();
String userInput;
usesrInput = getTyping.readLine;