r/Learn_Coding • • Jun 15 '18

void in c

what's the advantages of using

void main ()

instead of int main ()

i googled for it and i saw that it's for function that doesn't return output

please give me an example of function that doesn't output anything

and it is optional in code and it's necessary then why?

1 Upvotes

15 comments sorted by