()를 붙인다.const example = function(a, b, c) {
return a + b + c
}
example(1, 2, 3)
example.call(null, 1, 2, 3)
example.apply(null, [1, 2, 3])
this 를 대체하는 것!const obj = {
string: "yangwon",
print: function (behavior, object) {
console.log(`${this.string}이/가 지금 ${object}을/를 ${behavior}하고 있습니다.`)
}
}
const obj2 = {
string: "adela"
}
obj.print("꺼내기", "김치")
obj.print.call(obj2, "꺼내기", "김치") // this를 obj2로 바꿈

print는 obj의 메소드인데도 yangwon이 아니라 adela로 바뀌어 출력되었다.
즉, 다른 객체의 함수를 마치 자기 것마냥 사용할 수 있다.