...

/

Challenge 1: Compute Square of a Number

Challenge 1: Compute Square of a Number

Given a number, implement a function to compute the square of that number.

Problem Statement

Implement a function that takes a specific number testVariable and returns the square of the number.

Use the following mathematical identity to solve this problem: (n1)2=n22n+1(n-1)^2 = n^2 - 2n + 1 ...