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 global static? why we have to use static variable instead of Global variable
can u suggest me am in a confusion to choose whether to go to c programming or a software testing . am a graduate in B.sc(electronics).
write a program to reverse the words in the sentence.NOTE:not reverse the entire string but just the occurance of each word
What is a void * in c?
How do you list files in a directory?
What is pass by reference in c?
List some basic data types in c?
What is dangling pointer in c?
how to print 2-D array using a single for loop?
2 Answers Mind Tree, TCS, Value Labs,
what is the difference between c and c++?
What is the value of a[3] if integer a[] = {5,4,3,2,1}?
Total of how many functions are available in c?