Recently learned how to use function but the only thing that i don't get it is when to use int and void function? int need return to initialize while void don't need so most of the time all my function only void. Therefore, when need to declare int function instead of void?
So, a void function is a function that doesn't return anything, and an int function returns an integer. You can return what you want to according to your requirements, but read the above article until you fully understand.