Question: In a void function, if the return statement is not given, what will be the outcome ? Select one: a.The compiler throws an error and

In a void function, if the return statement is not given, what will be the outcome ? Select one:

a.The compiler throws an error and prevents the program from getting compiled.

b.There is no error and the function will return after executing the code in the body of the function.

c.The program stops executing and errors out at the end of the function.

d.The program never returns from the function.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

In most programming languages like C or Java a void function is a function that does not return any ... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!