Question

How does a value-returning function differ from the void functions?

How does a value-returning function differ from the void functions?

Homework Answers

Answer #1

Void functions are made and utilized simply like value-returning functions aside from they don't restore a value after the capacity executes. In lieu of an information type, void functions utilize the watchword "void." A void capacity performs a task, and afterward control returns back to the caller- at the same time, it doesn't restore a value. You could possibly utilize the return articulation, as there is no bring value back. Indeed, even without the return statement, control will re-visitation of the caller naturally toward the finish of the capacity. A decent usage of a void capacity is print a header/footer to a screen or file. Interestingly, a void capacity (technique or method, in different dialects) doesn't restore a function value. Nor is it called from inside an articulation. Rather, the function call shows up as a complete, independent statement

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
Describe how a LASER functions. How does a LASER differ from a continuum source? In your...
Describe how a LASER functions. How does a LASER differ from a continuum source? In your discussion, be sure to include a brief description of each of the four steps of lasing.  
Briefly describe photorespiration. How does this differ from the normal function of the Calvin Cycle?
Briefly describe photorespiration. How does this differ from the normal function of the Calvin Cycle?
How does an arbitrager differ from a speculator? How does a speculator differ from a hedger?
How does an arbitrager differ from a speculator? How does a speculator differ from a hedger?
How does Karl Marx’s theory of value differ from David Ricardo’s theory of value?
How does Karl Marx’s theory of value differ from David Ricardo’s theory of value?
a) Describe value creation on platforms. How does such value creation differ from value creation in...
a) Describe value creation on platforms. How does such value creation differ from value creation in traditional organisations? (1000 words) b) Use a platform of your own choice to illustrate how value creation occurs on digital platforms. (1000 words)
Describe value creation on platforms. How does such value creation differ from value creation in traditional...
Describe value creation on platforms. How does such value creation differ from value creation in traditional organisations? Use a platform of your own choice to illustrate how value creation occurs on digital platforms.
4) a) Describe value creation on platforms. How does such value creation differ from value creation...
4) a) Describe value creation on platforms. How does such value creation differ from value creation in traditional organisations? b) Use a platform of your own choice to illustrate how value creation occurs on digital platforms.
How does stakeholder emphasis of the creation of stakeholder value differ from the economic model? PLS...
How does stakeholder emphasis of the creation of stakeholder value differ from the economic model? PLS type
1.How does the structure of the testis differ from that of the ovary? How does male...
1.How does the structure of the testis differ from that of the ovary? How does male meiosis differ from female meiosis? What are some non-gonadal effects of hormones produced by the male? 2.Trace the pathway of sperm from the testis to the penile urethra. Indicate the function of all structures and glands along this pathway. 3.Discuss the Hypothalamic/Pituitary/Gonadal axis' role in male reproductive function, using the figure below to illustrate important feedback and hormonal influence on reproductive function. In your...
Experience with Functions Are the following statements a function header, a prototype or a function call?...
Experience with Functions Are the following statements a function header, a prototype or a function call? double calcMonthlyPmt(double amt); void displayResults() void showMenu(); showNum(45.67); area = CalArea(5,10); Write the function calls for the following headers and prototypes: void showValue(int quantity) void display(int arg1, double arg2, char arg3); pass the following to the call: int age; double income; char initial double calPay(int hours, double rate); What is the output of the following program? #include <iostream> using namespace std; void showDouble(int); //Function...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT