Study Guide for Test 2
For this test, you may bring one sheet (8.5" x 11") of handwritten notes.
This is the rough outline of topics that you will be tested on and possible
questions. Study chapters 4, 5, 6, and 12 from your book.
JavaScript
- A math quiz for elementary school kids on only one of these operations
- addition, subtraction, multiplication or division. Two random numbers
are shown for one of these operations. The users enters the result.
There is a button to show correct result and a refresh button for
another set of random numbers. The script does not keep score.
- A calculator that generates the nth term in a series,
like the Fibonacci series. There is one field for input and one field
for output, two buttons - one to calculate and the other to reset.
- Client side verification of input - like name, e-mail address, social
security number, or credit card information using regular expressions.
DHTML
- In the memory game, make sure that only a pair of grid elements are
revealed at a time. The previous pair must fade out before the new
pair is made visible.
- A simple tic-tak-toe game where a click on a grid square makes it
either a cross (X) or a knot (O) depending on the order.
PHP
- Read and write to files. Search for username and password.
- Read files in a directory.
- Keep a comment file that you can append to or display all its
contents.
- Use hidden variables to keep score in a quiz.
- Prompt someone coming to your site for the first time for their
name and then subsequently greet them by name. Use cookies.
- Automatically log out a person after 15 minutes of use. Use session
files.