Qsort + deal with input errors

Hello, I implemented a qsort (from cstdlib) and modify how read array works to avoid mistake while entering values.