write a c program to print "Welcome" without using semicolon
in the whole program ??
Answers were Sorted based on User's Feedback
Answer / vadivelt
main()
{
if(printf("Welcome"))
//Do nothing
}
Is This Answer Correct ? | 50 Yes | 18 No |
Answer / rama krishna sidhartha
main()
{
if(printf("Welcome"))
{
}
}
(OR)
main()
{
if(printf("Welcome"))
}
Is This Answer Correct ? | 13 Yes | 5 No |
Answer / manoj srivastava
#include<stdio.h>
#include<conio.h>
void main(void)
{
if(printf("welcome"))
{}
}
Is This Answer Correct ? | 5 Yes | 1 No |
Answer / sagar
try your self to run the above program then it wouldn't
display but then press (alt+F5) then u would get the
correct display
and....
its not possible with while loop ....
Is This Answer Correct ? | 8 Yes | 6 No |
Answer / peanut64
//C++
#include <iostream>
using namespace std;
void main()
{
while((cout<<"hello"<<endl)==false)
{
}
}
//c
#include <stdio.h>
void main()
{
while(printf("Hello")==false)
{
}
}
[My lecturer asked me this question. The above solution
works for me]
Is This Answer Correct ? | 2 Yes | 0 No |
Answer / kayalvizhi.s
#include<stdio.h>
{
main()
while(printf("welcome"))
}
Is This Answer Correct ? | 2 Yes | 0 No |
Answer / sandip kundu
#include<stdio.h>
#include<conio.h>
void main()
{
if(printf ("hi"))
getch();
}
Is This Answer Correct ? | 2 Yes | 2 No |
What is meant by 'bit masking'?
what is a c-language.what is do.
Explain the properties of union. What is the size of a union variable
What is the difference between scanf and fscanf?
Tell me what is null pointer in c?
What is the use of function overloading in C?
explain what is an endless loop?
What are the back slash character constants or escape sequence charactersavailable in c?
write a program to generate address labels using structures?
Explain void pointer?
Explain what does the format %10.2 mean when included in a printf statement?
What is the difference between realloc() and free()