The first lock consists of a panel filled with sparkling aems:diamondsrubies.emeraldsand so onBeside the panel is a row of buttonsone corresponding to each type of gem.To unlock the doorLin must press the button corresponding to the most common type of gem in the panel.Note that if there is a tie between the most common type of gem(iethere are equal numbers)then more than one button will need to be pressed.Your task is to write a function first lock(gems) that determines which button(s)should b