This change in the app.js file works as desired:
/*angular.module('app', [].controller('MainController', function() {
this.num1 = 0;
this.num2 = 0;
}));*/
var app = angular.module('app', []);
app.controller('MainController', function() {
this.num1 = 0;
this.num2 = 0;
});