finished JavaScript phone number exercise (w/o using a class)