final paper only for prof.hayyah
Overview
Those of you who have taken IT-130 with me will remember this type of assignment. The problems themselves are not difficult. However, they require you to demonstrate that you have been practicing with the material.
As has been reiterated, even with reading and reviewing the lectures, the only way to really ‘get’ this stuff is by actually typing out the code and experimenting with it on your own. You may completely understand what is going on with your initial review – and that is terrific – it’s a major hurdle sometimes. However, that is only perhaps one-third of the story. The rest of it comes from ‘making it your own’. And this happens only through practice and experimentation.
As a result, this assignment gives you a small number of pages that must be typed 100% from memory. For each page, I will give you a file to start with that has things like the basic tags, a document.ready() function, and a couple of CSS styles since I certainly would not ask you to type all of that out each time! But for each problem, the remainder must be typed without any reference other than this web page. If you need to look something up, then you must start again.
IMPORTANT: This objective of this assignment is absolutely NOT to get you to memorize code. In fact, it is the opposite. Rather, it is a means of making sure that you have been practicing on your own. If you have been practicing enough, then remembering how to invoke basic functions, or to, say, write an anonymous function should be relatively easy. It also prevents us from copying and pasting code that should be understood. Ultimately, completing each requirement should not be difficult as all you have to do is write a fairly small amount of relatively simple code to complete the problem.
Here is another deal: You MAY write out the solution ahead of time with your notes! But when it comes time to do the ‘homework’ version absolutely no peeking is allowed!
Honor System: Obviously, you are on the honor system for this one. I hope that you will not abuse my trust or that of your colleagues by taking advantage of it.
It’ll be on the test: Another reason to start doing these things from memory is that you will have to do a few of these kinds of questions on your final exam!
The assignment
Problem #1 (20 points): Download a ‘fresh’ copy of page_of_stuff.htm from the class web page and rename it to a4p1.htm (i.e. assignment 4, problem 1). From memory, modify this page so that whenever the user moves the mouse over any list item (e.g. ‘Apple’), the font decreases by 20% (i.e. to 80% of its original size). When they move the mouse off of any list item, the font goes back to its original size. The name of the CSS property to change a font is ‘font-size’. Remember that you MAY work out this problem WITH your notes beforehand. However, for your submission, this problem must be done using a fresh copy of the file and all the remaining code filled in from memory. You MAY, however, look at this web page (e.g. to remind yourself that the property name is ‘font-size’).
Tip: If you do not see the two lists (Fabulous Fruit, and Varied Veggies), then you may be using a cached page. Be sure to right-click the file and save it to your hard drive to ensure that you have the most current version of this file.
Problem #2 (20 points): This problem does NOT have to be done from memory!
A. Download a ‘fresh’ copy of page_of_stuff.htm and rename this one to a4p2.htm (i.e. assignment 4, problem 2). Somewhere on the page, create a radio button with options for ‘Images of Trucks’and ‘Images of Balls’. Next to this radio button, have a regular button that invokes a function that does the following: Depending on which the user chooses, report how many of those items are present on the page. So if they choose ‘Images of Trucks’, report back on the number of these images on the page (i.e. 1 in this case). You should report this by appending a line of text to the bottom of the div section containing your radio button.
B. Experiment: Go to your textbook or any reference and look up two events that were not discussed in the events part 1 lecture. Demonstrate the use of those events in your code. For credit, you must also document (using a comment) where you are using the event.
Assignment Submission:
Same requirements as last time (and as in the future):
1. Please ZIP (do not use RAR or TAR, etc)
2. Throughout the course, any accessory files that may be required by the assignment such as images, external CSS files, external JS files, etc should be included in your zip file.
4. You do not have to upload to the server.