Boolean and Void problem

后端 未结 3 1875
时光取名叫无心
时光取名叫无心 2021-01-29 09:53

So here is my code a little more edited however now I\'m stuck on the success parameter:

#include 
#include         // need this in         


        
3条回答
  •  醉话见心
    2021-01-29 10:00

    You've got return total in a function that returns void. void means that the function returns nothing.

    Methinks you expect return total to update the total parameter in your call, but that's not the way it works.

    Better go back to square one and read about value parameters and function results.

提交回复
热议问题