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...


get any number as input except 1 and the output will be
1.without using operators,expressions,array,structure.don't
print 1 in printf statement

Answers were Sorted based on User's Feedback



get any number as input except 1 and the output will be 1.without using operators,expressions,array..

Answer / bheemakarna1989

example
input : 4554
output : 1



input :567
output : 1

Is This Answer Correct ?    4 Yes 0 No

get any number as input except 1 and the output will be 1.without using operators,expressions,array..

Answer / karna

void main()
{
int n;
printf("%d",scanf("%d",n));
getch();
}

Is This Answer Correct ?    2 Yes 1 No

get any number as input except 1 and the output will be 1.without using operators,expressions,array..

Answer / amarnathreddy

i am going to write only logic
n=1000
n1=n-(n-1)
1000-999=1

Is This Answer Correct ?    3 Yes 4 No

Post New Answer

More C Interview Questions

What are loops in c?

0 Answers  


what is the differnce between AF_INET and PF_INET?

5 Answers   Systems Plus, Wipro,


Explain enumerated types in c language?

0 Answers  


what is pointer?

4 Answers  


What is openmp in c?

0 Answers  


What is main return c?

0 Answers  


what is call by value and call by reference

4 Answers  


An expression to whose value an operater is applied a) operand b) variable c) constant d) all of the above

0 Answers  


Write a client and server program in C language using UDP, where client program interact with the Server as given below: i) The client begins by sending a request to send a string of 8 characters or series of 7 numbers, the server sends back a characters or numbers as per the request of the client. ii) In case of series of 7 numbers: The client sends a multiplication of numbers, to the server. iii) In case of a string of 8 characters: The client sends a reverse order of string to the server.. iv) Server will send an acknowledgment to the client after receiving the correct answer

0 Answers   Ignou, Microsoft,


Can we include one C program into another C program if yes how?

7 Answers   Infosys,


What is the difference between int main and void main in c?

0 Answers  


#include<stdio.h> #include<conio.h> void main() { char ch='\356'; printf("%d",ch); } o/p=-18 why?plz.explain

2 Answers  


Categories