So probably a silly question. How does this function know to replace "obj" with whatever object I put in, and replace "checkProp" with whatever property I put in? I'm pretty much just starting and feel like I may have missed something or just forgot. Thanks in advance!
function checkObj(obj, checkProp) {
if (obj.hasOwnProperty(checkProp)) {
return obj[checkProp];
}
else {
return "Not Found";
}
return "Change Me!";
}