Renamed the result variables

Renamed the result variables and updated readme to reflect this change.
Fixed global variable names