beautify 1st part of the tutorial

This commit is contained in:
Ilya Kantor 2015-03-10 12:36:58 +03:00
parent e3dd2cedc0
commit 6444024a9d
327 changed files with 2358 additions and 1986 deletions

View file

@ -4,20 +4,20 @@
//+ run demo
var numbers = [];
while(true) {
while (true) {
var value = prompt("Введите число", 0);
if (value === "" || value === null || isNaN(value)) break;
numbers.push(+value);
}
var sum = 0;
for(var i=0; i<numbers.length; i++) {
for (var i = 0; i < numbers.length; i++) {
sum += numbers[i];
}
alert(sum);
alert( sum );
```