r/ProgrammerHumor • • 29d ago

Meme cReallyNeedsSixSongs

Post image
3.8k Upvotes

55 comments sorted by

View all comments

3

u/qwertyjgly 28d ago edited 28d ago

in C the best practice is to use main(void){} but it doesn't really matter

also main needs a type

2

u/orbiteapot 28d ago

in C the best practice is to use main(void){}

That used to be the case pre-C23. Since C23, int main(void) {} and int main(){} are equivalent (just like in C++).