Update calc.cpp

Added a square Function in the program