Is it possible to print a name without using commas, double quotes,semi-colons?
Answers were Sorted based on User's Feedback
Answer / vinay
void main()
{
char s[30]=
{72,69,76,76,79,33,32,84,72,73,83,32,73,83,32,86,73,78,65,89,32,83,65,76,76,65};
if(printf(s));
getch();
}
Is This Answer Correct ? | 7 Yes | 2 No |
Answer / vinay salla
Explanation for above solution:
The answer is based on the ascii values..
We can take the ascii values of the characters together in
one char array..
Is This Answer Correct ? | 3 Yes | 2 No |
Answer / pavan_mustyala
int main(int argc, char* argv[])
{
if(putchar('n') && putchar('a') && putchar('m') &&
putchar('e'))
{
}
return 0;
}
Is This Answer Correct ? | 3 Yes | 2 No |
Answer / saravanan
#include<stdio.h>
#define fun(x) #x
int main()
{
if(printf(fun(INDIA))){}
}
Is This Answer Correct ? | 1 Yes | 0 No |
Answer / srsabariselvan
void main()
{
if(printf("www.sslogic.blogspot.com"))
{
}
}
Is This Answer Correct ? | 2 Yes | 6 No |
Answer / amit rathi
main ()
{
if (printf (hello))
return 0;
}
//printf returns number of characters printed so if
condition turns true.
same can be done with while,shitch,etc.
Is This Answer Correct ? | 14 Yes | 23 No |
void main() { char a[]="12345\0"; int i=strlen(a); printf("here in 3 %d\n",++i); }
Write out a function that prints out all the permutations of a string. For example, abc would give you abc, acb, bac, bca, cab, cba. You can assume that all the characters will be unique.
5 Answers IITR, Microsoft, Nike,
main() { char c; int i = 456; clrscr(); c = i; printf("%d", c); } a. 456 b. -456 c. random number d. none of the above
Write a routine to implement the polymarker function
main() { 41printf("%p",main); }8
main() { char *a = "Hello "; char *b = "World"; clrscr(); printf("%s", strcpy(a,b)); } a. “Hello” b. “Hello World” c. “HelloWorld” d. None of the above
4 Answers Corporate Society, HCL,
main() { int c = 5; printf("%d", main||c); } a. 1 b. 5 c. 0 d. none of the above
How to palindrom string in c language?
Implement a t9 mobile dictionary. (Give code with explanation )
1 Answers Amazon, Peak6, Yahoo,
Is there any difference between the two declarations, 1. int foo(int *arr[]) and 2. int foo(int *arr[2])
Is the following code legal? typedef struct a aType; struct a { int x; aType *b; };
What are the following notations of defining functions known as? i. int abc(int a,float b) { /* some code */ } ii. int abc(a,b) int a; float b; { /* some code*/ }