c++ - no duplicate function for a lottery program -


right im trying make function checks see if user’s selection in array , , if itll tell choose diff number. how can this?

do mean this?

bool checknumberisvalid() {    for(int = 0 ; < array_length; ++i)    {       if(array[i] == user_selection)          return false;    }     return true; } 

that should give clue, @ least.


Comments

Popular posts from this blog

c# - how to write client side events functions for the combobox items -

exception - Python, pyPdf OCR error: pyPdf.utils.PdfReadError: EOF marker not found -