Proxym-IT interview question

sort an array PPCM / PGCD