Skip to content

Commit 0f87177

Browse files
committed
feat(contains): add some basic examples
1 parent cc29bbd commit 0f87177

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

14_contains/README.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
11
# Exercise 14 - contains
22

33
Write a function that searches for a value in a nested object. It returns true if the object contains that value.
4+
5+
Objects are compared by reference.
6+
7+
Examples:
8+
9+
```javascript
10+
contains({ foo: "foo" }, "bar") // true
11+
contains({ foo: { bar: "bar" } }, "bar") // true
12+
```

0 commit comments

Comments
 (0)