Weeks 9 - 12 - JavaScript review, windows and frames
Case studies: building images from scratch ,
Appending and removing rows of a table
Event handlers -- assigning dynamically using function(){}(and traversing nodes)
Things you really ought to know:
random numbers, (teleology, mechanism and pragmatism) and evaluating a random number generator
why this approach to sampling with replacement is bad
Take Home Quiz: Due November 24th
Review: Nov. 10 - 21 (All are due Nov. 21)
Assignment #5A: Image Scrambler --
Draw either a tree or a face. Your drawing should each be exactly 300 pixels by 300 pixels in size, and in either .jpg or .png format. Make the picture as realistic as you can (work no more than three hours on each). Slice the image into nine pieces, each 100 pixels square. Create a 3 by 3 table containing the nine pieces. Whenever someone clicks a button, randomly scramble the nine pictures, taking care that each picture appears only once. Assignment #5A: Puzzle of 8 --
Draw either a tree or a face. Your drawing should each be exactly 300 pixels by 300 pixels in size, and in either .jpg or .png format. Make the picture as realistic as you can. Slice the image into nine pieces, each 100 pixels square. Create a 3 by 3 table containing eight of the nine pieces (in some predefined, but scrambled order) with one remaining cell left blank. Whenever someone clicks on a picture next to the blank cell (either above, left, right or below it), swap the position of the blank and non-blank cells. When the picture is reassembled (i.e., all eight slices are in their proper positions, then replace the blank picture by the missing ninth piece.
Poll Taker--
Create a table that fills the entire top 3/4 of the screen with 100 rectangles (measuring the screen to determine the size of the rectangles, that are placed 10 cells per each of 10 rows). Choose between 6 and 10 different colors that "go nicely together." Whenever a button (appearing in the bottom quarter of the screen) is pushed use your colors to fill the colors of the table cells at random. Whenever a second button is clicked, generate a report which shows the total number of cells having each of the colors used. (For example, if six colors have been used, we would expect about 100/6 or 16.7 cells to end up having each of these six colors.)
Work on previous assignments: