  *
  * This example extends the BorderDetect example, which makes use of the onboard Zumo Reflectance Sensor Array
  * and its associated library to detect the border of the sumo ring.  It also illustrates the use of the 
- * ZumoMotors, PushButton, and ZumoBuzzer libaries.
+ * ZumoMotors, PushButton, and ZumoBuzzer libraries.
  *
  * In loop(), the program reads the x and y components of acceleration (ignoring z), and detects a
  * contact when the magnitude of the 3-period average of the x-y vector exceeds an empirically determined

#include <Wire.h>
#include <LSM303.h>

/* This example uses the accelerometer in the Zumo Shield's onbaord LSM303DLHC with the LSM303 Library to 
 * detect contact with an adversary robot in the sumo ring. The LSM303 Library is not included in the Zumo 
 * Shield libraries; it can be downloaded separately from GitHub at: 
 *

  if (_cnt < _size) _cnt++;
}

// returns the average of the data-set added so far
template <typename T>
T RunningAverage<T>::getAverage() const
{
