Brilliant Earth Interview Question

Metal math question.