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 |
how to find your architecture is LittleEndian or BigEndian?
Can we change the value of #define in c?
illustrate the use of address operator and dereferencing operator with the help of a program guys plzzz help for this question
Why c is called top down?
What is true about the following C Functions a.Need not return any value b.Should always return an integer c.Should always return a float d.Should always return more than one value.
Given an array of numbers, except for one number all the others occur twice. Give an algorithm to find that number which occurs only once in the array.
How do you redirect a standard stream?
what is the difference between : func (int list[], ...) or func (int *list , ....) - what is the difference if list is an array and if also if list is a pointer
Is it possible to have a function as a parameter in another function?
What is calloc()?
main() { int l=6; switch(l) { default:l=l+2; case 4:l=4; case 5:l++; break; } printf("%d",l); }
Should a function contain a return statement if it does not return a value?