+ 1

Do functions have a type like other identifiers? If yes how is it derived? (In C program)

28th May 2020, 2:12 PM
Adarsh
Adarsh - avatar
2 odpowiedzi
+ 2
The return type is defined within the function declaration, e.g. -> int main() has return type int The same is indicated by: -> return 0 which is an int as well If you are using unknown libraries and do not know the implementation, you should take return values very carefully.
28th May 2020, 3:40 PM
Sandra Meyer
Sandra Meyer - avatar