Due Monday Nov 11 at 11:59pm.
Carefully study the examples on the resources page: A function to convert from celsius to fahrenheit, Calling a function to change colors in a page, Calling a function with parameters.
Write a web page that prompts the user for two numbers and
prints their average. You must write the computation of average as a
function average
that takes two numbers and returns their
average.
Write a function that takes a color and changes the background of the
entire page to that color. Note
that in our examples the <body>
tag has an
id thepage
.
Add two buttons to the page (each in its own form): one to set the page background to any color, the other one to restore it back to white. Both buuttons should call the same function, just with different colors.
This page is a part of CSci 1001 course web site.