Computer Science, asked by Siddharthcs150, 2 months ago

BRAINLIST GUARANTEED

Q1.In What situation does a function return a value?

Q2.State two features of a constructor.​

Answers

Answered by kanugulanavya1527
0

Answer:

1)A return is a value that a function returns to the calling script or function when it completes its task. A return value can be any one of the four variable types: handle, integer, object, or string. The type of value your function returns depends largely on the task it performs.

2) Constructors are called automatically when the objects are created. Constructors should be declared in the public section to be availabile to all the functions. Constructors do not have return type , not even void and therefore they can not return value.

Explanation:

Similar questions