#include"math.h"
void main()
{
printf("Hi everybody");
}
if <stdio.h> will be included then this program will must
compile, but as we know that when we include a header file
in "" then any system defined function find its defination
from all the directrives. So is this code of segment will
compile? If no then why?
Answers were Sorted based on User's Feedback
Answer / er. preeti
There is no error in this code. If you will compile this
code in Borland Turbo C++ compiler, then the program will
be compiled easily and no error will be shown at that
time. In addition, if you want the output then include
getch(); after the printf statment. You will get the
output definetly.
#include "math.h"
void main()
{
printf("Hi Everybody");
getch();
}
| Is This Answer Correct ? | 3 Yes | 0 No |
Answer / siva.kumar
above error will come
error C3861: 'printf': identifier not found
| Is This Answer Correct ? | 0 Yes | 1 No |
given integer number,write a program that displays the number as follows: First line :all digits second line : all except the first digit . . . . Last line : the last digit
pls anyone can help me to write a code to print the values in words for any value.Example:1034 to print as "one thousand and thirty four only"
main() { static int a[3][3]={1,2,3,4,5,6,7,8,9}; int i,j; static *p[]={a,a+1,a+2}; for(i=0;i<3;i++) { for(j=0;j<3;j++) printf("%d\t%d\t%d\t%d\n",*(*(p+i)+j), *(*(j+p)+i),*(*(i+p)+j),*(*(p+j)+i)); } }
int DIM(int array[]) { return sizeof(array)/sizeof(int ); } main() { int arr[10]; printf(“The dimension of the array is %d”, DIM(arr)); }
What is the hidden bug with the following statement? assert(val++ != 0);
main() { void swap(); int x=10,y=8; swap(&x,&y); printf("x=%d y=%d",x,y); } void swap(int *a, int *b) { *a ^= *b, *b ^= *a, *a ^= *b; }
#include <stdio.h> #define a 10 main() { #define a 50 printf("%d",a); }
int a=1; printf("%d %d %d",a++,a++,a); need o/p in 'c' and what explanation too
main() { int i=-1; -i; printf("i = %d, -i = %d \n",i,-i); }
main() { printf("\nab"); printf("\bsi"); printf("\rha"); }
how to concatenate the two strings
Print an integer using only putchar. Try doing it without using extra storage.