(Natural numbers and their squares) Knowing that (x + 1)2 = x2 + 2x + 1, and that multiplication is more time consuming than addition, write an efficient program that displays the first ten natural numbers and their squares. Knowing that (x + 1)3 = x3 + 3x2 + 3x + 1, the same process can be followed to display the cubes of these numbers. Here is a sample run:
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here