diff --git a/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-functional-programming-by-building-a-spreadsheet/646d4626420eeecd51f241c2.md b/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-functional-programming-by-building-a-spreadsheet/646d4626420eeecd51f241c2.md index 21236e19958..f01f519ea6d 100644 --- a/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-functional-programming-by-building-a-spreadsheet/646d4626420eeecd51f241c2.md +++ b/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-functional-programming-by-building-a-spreadsheet/646d4626420eeecd51f241c2.md @@ -11,6 +11,22 @@ Update the callback function to take `match`, `fn`, and `args` as parameters. It Remember to make `fn` lower case. +To check if a property on a given object exists or not, you can use the hasOwnProperty() method. + +The `hasOwnProperty()` method returns `true` or `false` depending on if the property is found on the object or not. + +Here is an example of how to use the `hasOwnProperty()` method: + +```js +const developerObj = { + name: 'John', + age: 34, +} + +developerObj.hasOwnProperty('name'); // true +developerObj.hasOwnProperty('salary'); // false +``` + # --hints-- Your callback function should have `match` as the first parameter.