Print all numbers which has a certain digit in a certain
position
eg:
number=45687
1 number=4
2 number=5
etc
Answer Posted / eranna
#include<stdio.h>
#include<conio.h>
void main()
{
int n,t,cnt=1;
clrscr();
printf("\nEnter The No.");
scanf("%d",&n);
while(n%10!=0)
{
t=n%10;
n=n/10;
printf("\n %d number= %d",cnt,t);
cnt++;
}
getch();
}
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
In which header file is the null macro defined?
any limit on the number of functions that might be present in a C program a) max 35 functions b) max 50 functions c) no limit d) none of the above
What is #ifdef ? What is its application?
What does %2f mean in c?
How can I read and write comma-delimited text?
Which one would you prefer - a macro or a function?
What is table lookup in c?
Who developed c language and when?
What is exit() function?
How can I call fortran?
Q.1 write a program to create binary tree 1 to 16 numbers? Q.2 write a program to creat a binary search tree for the member that is given by user?
Explain why C language is procedural?
main use of recursive function a) processing speed high b) reduce program length/reduce repeated statements c) if you do not, use iterative methods like, for, while or do-while d) all the above
What is static and auto variables in c?
What is selection sort in c?