Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


Print all numbers which has a certain digit in a certain
position
eg:
number=45687
1 number=4
2 number=5
etc

Answers were Sorted based on User's Feedback



Print all numbers which has a certain digit in a certain position eg: number=45687 1 number=4 2..

Answer / vaibhav

#include<stdio.h>
#include<conio.h>
void main()
{
int n,t,i,cnt=1;
clrscr();
printf("\nEnter The No.");
scanf("%d",&n);
while(n%10!=0)
{
n=n%10;
t=n/10;
printf("\n %d number= %d",cnt,t);
cnt++;
}
getch();
}

Is This Answer Correct ?    2 Yes 2 No

Print all numbers which has a certain digit in a certain position eg: number=45687 1 number=4 2..

Answer / 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

Print all numbers which has a certain digit in a certain position eg: number=45687 1 number=4 2..

Answer / eranna kybarshi

#include<stdio.h>
#include<conio.h>
void main()
{
int i,n,t,cnt=0;
int num[10];
clrscr();
printf("\nEnter The No.");
scanf("%d",&n);
while(n%10!=0)
{
t=n%10;
num[cnt]=t;
n=n/10;
cnt++;
}
num[cnt]='\0';

for(i=cnt-1;i>-1;i--)
printf("\n %d number= %d",cnt-i,num[i]);
}

Is This Answer Correct ?    0 Yes 0 No

Print all numbers which has a certain digit in a certain position eg: number=45687 1 number=4 2..

Answer / vignesh1988i

sorry ... i could not understand ur question
properly....... can you post it again.... if
possible!!!!!!!!!!!!please

Is This Answer Correct ?    0 Yes 1 No

Post New Answer

More C Interview Questions

in malloc and calloc which one is fast and why?

1 Answers  


How to removing white spces in c programming only bu using loops

2 Answers  


write a c program thal will find all sequences of length N that produce the sum is Zero, print all possible solutions?

0 Answers   Wipro,


#include main() { enum _tag{ left=10, right, front=100, back}; printf("left is %d, right is %d, front is %d, back is %d",left,right,front,back); }

0 Answers   Wilco,


Tell me when is a void pointer used?

0 Answers  


How can I increase the allowable number of simultaneously open files?

1 Answers   CSC,


What are pointers?

0 Answers   Accenture, Tavant Technologies, Zensar,


which one is better structure or union?(other than the space occupied )

2 Answers  


ATM machine and railway reservation class/object diagram

0 Answers   Zycus Infotech,


How can I find the modification date and time of a file?

0 Answers  


Can you apply link and association interchangeably?

0 Answers   InterGraph,


Write a programe print the sum of series 0,1,2,.....10

7 Answers  


Categories