JS Problem Challenge

Selesaikan tantangan pemrograman JavaScript — tulis fungsi yang lolos semua test case.