Help needed in MaxSubArraySum

Please format your code - the forum software has mangled it and it won’t compile! :slight_smile: