Ask Question
31 January, 02:39

What is the value of choice after the following statements? void getChoice (int& par_choice, int par_count); int choice, count = 3; getChoice (choice, count); void getChoice (int& par_choice, int par_count) { if (par_count <0) par_choice = 0; if (par_count = 0) par_choice = - 1; else par_choice = 99; return; }

+2
Answers (1)
  1. 31 January, 05:30
    0
    In every programming language the return type of the function is must but here in the given code the return type for the following function is not given so this program will cause a syntax error that no return type is defined for the function getchoice.

    getChoice (choice, count);

    it should be like:

    returntype getchoice (params);
Know the Answer?
Not Sure About the Answer?
Get an answer to your question ✅ “What is the value of choice after the following statements? void getChoice (int& par_choice, int par_count); int choice, count = 3; ...” in 📙 Computers & Technology if there is no answer or all answers are wrong, use a search bar and try to find the answer among similar questions.
Search for Other Answers