Lab 4.1 - Factorial

Arkangel factorial by Arkangel, http://flickr.com/photos/arkangel/155059880/

The factorial function, written as n! in math, is where you mulitply all of the whole numbers from 1 to whatever n is. Thus:

Create an application that asks for a number from the user and displays the factorial of that number. Your program should error-check to make sure that the user hasn't entered a negative value.

HINTS: Use either a Do-Loop-While or a Do-While-Loop (you'll have to figure out which) to run not only the factorial algorithm, but also the error-checking for numbers less than 0. Don't be afraid to add an extra variable if you need one. Use a good sentinel and a variable to keep track of the answer. Factorial numbers get really big, really fast so use a Long instead of an Integer.