#include"stdio.h"
#include"conio.h"
void main()
{
int a;
printf("\n enter a number:");
scanf("%c\n");
getch();
}

Answers were Sorted based on User's Feedback



#include"stdio.h" #include"conio.h" void main() { int a; printf("\n en..

Answer / parvathy mohan

# include <stdio.h>
# include <conio.h>
void main()
{
int a;
printf("\n enter a number");
scanf("%d",&number);
getch();
}

Is This Answer Correct ?    12 Yes 15 No

#include"stdio.h" #include"conio.h" void main() { int a; printf("\n en..

Answer / pawanjha12

Here in the scanf("%c\n");
it is just take a input. and, it will store that input
value anywhere.
it would be just garbage value. ok.........
nothing is output.
say, null pointer assignment.........


Is This Answer Correct ?    2 Yes 5 No

Post New Answer

More C C++ Errors Interview Questions

Given an int variable n that has already been declared and initialized to a positive value, and another int variable j that has already been declared, use a do...while loop to print a single line consisting of n asterisks. Thus if n contains 5, five asterisks will be printed. Use no variables other than n and j .

2 Answers  


How to upgrade LOOP environment, I just mean, how can i make loop statement editable ? I just try some program using loop statement and checking it in multiple compilers. Every compiler showing different output, what's the wrong ? is it a compiler based problem, or loop based problem, tell me why ? and what will be the debugging process, for this kind of problem ?

1 Answers  


How to reverse a linked list without using array & -1? Thank you.

2 Answers   Access, Satyam,


quoroum of computer languages?

0 Answers   Infosys,


I can not get my C++ program to work right. It is supposed to tell if a word is a palindrome or not, but it only tells thet the word is not a palindrome. And I can't fix it.

1 Answers  






Why are memory errors hard to debug?

1 Answers  


what is syntax error?

3 Answers  


A sample program using data structure? what is file handling?

0 Answers   TCS,


difference between c/c++ programing language? what is necessesity of c++ when existing c programing language?

2 Answers   TCS,


I am using Qt 5.6 during compilation it stops and gives error about Qmake The process "C:QtQt5.6.35.6.3msvc2015_64inqmake.exe" crashed. Error while building/deploying project untitled1 (kit: Desktop Qt 5.6.3 MSVC2015 64bit) When executing step "qmake"

0 Answers  


Write a program to accept two strings of Odd lengths. Then take all odd characters from one string and even characters from the other and concatenate and produce a string.

1 Answers  


Assume that the int variables i and j have been declared, and that n has been declared and initialized. Write code that causes a "triangle" of asterisks of size n to be output to the screen. Specifically, n lines should be printed out, the first consisting of a single asterisk, the second consisting of two asterisks, the third consistings of three, etc. The last line should consist of n asterisks. Thus, for example, if n has value 3, the output of your code should be * ** *** You should not output any space characters. Hint: Use a for loop nested inside another for loop.

2 Answers   HCL,


Categories