ring.html: computes area of a ring

<script>
    var r1, r2;
    r1 = prompt("Enter radius 1")
    while (r1 != null) {
    	r2 = prompt("Enter radius 2")
        alert("area = " + (area(r1) - area(r2))) // parens are needed!
        r1 = prompt("Enter radius 1")
    }

    function area(r) {
    	return 3.14 * r * r
    }
</script>