if length of num array less than 3, it even cannot get 3 numbers