Implements calculatePower, switches to ArrayList and double

calculatePower is now implemented! Also, ArrayList is like C++ vector,
not Vector.