I hereby claim:
- I am wendy on github.
- I am wendy (https://keybase.io/wendy) on keybase.
- I have a public key ASAk0qGFvbVTJNSbFFiXHtnNecuvTYJ-VvCCsHrBfDpCswo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
//Call vs Apply | |
var greet = function(name, state) { | |
console.log('Hi ' + name + ' from ' + state + '.'); | |
}; | |
greet('Wendy', 'New York'); // 'Hi Wendy from New York.' | |
//What if we put that info into an array instead? | |
var wendy = ['Wendy', 'New York']; |
//Arguments object | |
//Take for example a function that sums up two numbers: | |
var sum = function(a,b) { | |
return a + b; | |
}; | |
sum(1,5); // 6 | |
//What if we wanted to sum up three numbers? We can add another parameter like this: |