Stop watch using pure javascript