Skip to content

Commit f981ebf

Browse files
authored
Merge pull request sadanandpai#36 from hardyganatra/HardikGanatra-main
Fixed #Q21 collections-challenges
2 parents a49ac11 + da14866 commit f981ebf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

challenges/collections-challenges.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -480,7 +480,7 @@ const map = new Map();
480480
481481
arr.forEach(obj => {
482482
if (map.has(obj.id)) {
483-
if (obj.rank > map.get(obj.id)) {
483+
if (obj.rank < map.get(obj.id).rank) {
484484
map.set(obj.id, obj);
485485
}
486486
} else {

0 commit comments

Comments
 (0)