The guest who is not there

A guest lookup can finish without finding a booking.

your task

Print the room when the guest has a booking. Otherwise print “no booking for ” followed by the guest’s name.

The lookup prints Jonas’s room. For Tove, it stops while reading room. Both cases search bookings for the guest named in wanted.

Starter code
or press Ctrl EnterNot run yet

cases

Not run yetJonas has a booking

Expected output

1Birch
See the input and the code for this case
const bookings = [{ guest: "Mira", room: "Atlas" }, { guest: "Jonas", room: "Birch" }];
const wanted = "Jonas";
Not run yetTove has no booking

Expected output

1no booking for Tove
See the input and the code for this case
const bookings = [{ guest: "Mira", room: "Atlas" }, { guest: "Jonas", room: "Birch" }];
const wanted = "Tove";