mohua_banerjee
asked on
cprogramming
can i write a c program without main()
function in the program?
function in the program?
Posted twice pls delete.
No there must have void main() for all programs.
This is already a standard.
This is already a standard.
Even I wrote already that this question was posted twice you give an answer. And the answer is wrong too.
Sure one can write a C programm without any main function. The only change is taht you can't execute such a program directly. But for linking, building libraries, unsing as an external module ... it can be used.
Sure one can write a C programm without any main function. The only change is taht you can't execute such a program directly. But for linking, building libraries, unsing as an external module ... it can be used.
rbr is right. you can compile a C program without the main() function. however, you will defineitely give a linking error when you try to create an executible from it.
pagladasu
pagladasu
I have withdrawn my answer.
Sorry about that.
hongjun
Sorry about that.
hongjun
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
i am also supporting to msivari.
Any C program must have to start with
main().With out main() we can't execute the program..
Any C program must have to start with
main().With out main() we can't execute the program..
ASKER
i want to close the answer as this is enough.