Fixed minor warnings
-Initialized variable used in summation
-Changed string comparisons to official NSString method