how to create c progarm without void main()?
Answer / surya bhagavan s
#include<stdio.h>
#include <unistd.h>
_start()
{
_exit(my_main());
}
int my_main(void)
{
printf("Hello\n");
return 42;
}
for compilation
gcc -o3 -nostartfiles example.c
| Is This Answer Correct ? | 2 Yes | 7 No |
What is typedf?
Explain what is the benefit of using an enum rather than a #define constant?
fn f(x) { if(x<=0) return; else f(x-1)+x; }
how does the C compiler interpret the following two statements p=p+x; q=q+y; a. p=p+x; q=q+y b. p=p+xq=q+y c. p=p+xq; q=q+y d. p=p+x/q=q+y
What is a pointer and how it is initialized?
Why is a semicolon (;) put at the end of every program statement?
write a program in C that prompts the user for today's date,tomorrow's date and display the results.Use structures for today's date,tomorrow's date and an array to hold the days for each month of the year.
why do we use # in c-language?
Write c-code for 5+55+555+5555+55555+555555+5555555. Output will be it's answer...
main() { int i; printf("%d",i^i); }
What does typeof return in c?
What is the difference between fread buffer() and fwrite buffer()?