prop in object
Parameters: This function accepts the following parameter as mentioned above and described below:
- prop: This parameter holds the string or symbol that represents a property name or array index.
- object: This parameter is an Object which to be checked whether it contains the prop.
Return value: This method returns an boolean values :
- true: The value true is returned if the specified property is found in an object.
- false: The value false is returned if the specified property is not found in an object.
> true > true > false > false > false > true
> true > false > "GEEKSFORGEEKS"
- Google Chrome
- Internet Explorer
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.