can we print any string without using terminator?
Answers were Sorted based on User's Feedback
Answer / yogesh bansal
Yes, We can print the string without using the terminator.
like this
#include <stdio.h>
int main()
{
if(printf("this is yogesh"))
{
printf("then you must be good boy");
}
return 0;
}
Its a working example. when the control comes to if()
statement. first it will execute the printf statement inside
if() and the printf function will return number of character
printed which is an integer value and if() is true for any
value greater than 0. so it will go inside and execute the
rest of the code.
Hope the explanation is clear to you.
| Is This Answer Correct ? | 30 Yes | 3 No |
Answer / ashutosh
the format should b like this
void main()
{
if(printf("i luv u deepa")
{
}
}
| Is This Answer Correct ? | 17 Yes | 3 No |
What is meant by 'bit masking'?
what is the use of getch() function in C program.. difference b/w getch() and getche()??
29 Answers HCL, IBM, Infosys, TCS, Wipro,
#include<stdio.h> int main() { int a[3][3][2]= {1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18}; printf("%d\n",*(*(*a+1)); return 0; } What will be the output of the above question? And how?
How many loops are there in c?
What are the two forms of #include directive?
Which control loop is recommended if you have to execute set of statements for fixed number of times?
create a C program that displays one z,two y's,three x's until twenty six A's. plzz answer i need it tomorrow.
What is the maximum no. of arguments that can be given in a command line in C.?
Is both getch() and getchar() functions are similar? if it is similar means why these two functions are used for same usage? if it is not similar means what is the difference?
what is difference between ANSI structure and C99 Structure?
which is the best site or book for learning C...and i need the content for C..how to get the good programming skills....? can plz suggest me....
Give a method to count the number of ones in a 32 bit number?