When most people think of dice, they think of little six-sided cubes with numbers on them. However, there are many more types of dice with different sides.
Create an application that takes a number of sides from the user and then rolls a virtual die with that many sides. Your program should error-check the number of sides given to make sure that it's greater than zero, and display the word "error" if it isn't. Otherwise, it should display a random number (a whole number, thank you) between 1 and the number given by the user.
Here's an object list (aren't I nice?):
As always, design a useful and proper interface. It would be nice if you didn't use the same random seed each time the program runs. You may assume the user isn't a goob and will enter numerical values.