mirror of
https://github.com/github/codeql.git
synced 2026-04-01 05:08:15 +02:00
11 lines
164 B
JavaScript
11 lines
164 B
JavaScript
var adder = {
|
|
sum: 0,
|
|
add: function(x) {
|
|
this.sum += x;
|
|
},
|
|
addAll: function(xs) {
|
|
xs.forEach(function(x) {
|
|
this.sum += x;
|
|
}, this);
|
|
}
|
|
}; |