Follow Our FB Page << CircleMedia.in >> for Daily Laughter. We Post Funny, Viral, Comedy Videos, Memes, Vines...

when user give a number it multiply with 9 without
useing '+' and '*' oprator

Answer Posted / guest

#include<stdio.h>
#include<conio.h>
#include<math.h>
void main()
{clrscr();
int a,i,r=0;
scanf("%d",&a);

for(i=a;i>0;i--)
r=r-9;
r=abs(r);
printf("%d",r);
getch();
}

Is This Answer Correct ?    4 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why clrscr is used after variable declaration?

404


Write a program to print factorial of given number without using recursion?

229


Do you know pointer in c?

254


What is a pointer on a pointer in c programming language?

239


Can we change the value of constant variable in c?

190






How do I determine whether a character is numeric, alphabetic, and so on?

252


What does it mean when the linker says that _end is undefined?

227


2) Write a program that will help Air Traffic Control for an airport to view the sequence of flights ready for take-off. The airport can accommodate 10 flights waiting for take-off at any point in time. Each flight has a unique 3 digit numeric identifier.  Each time a flight takes-off, Air Traffic Control adds a flight to the waitlist. Each time a flight is added to the waitlist, the list of flights waiting to take-off must be displayed.  When a flight is cleared for take-off, Air Traffic Control removes the flight from the waitlist. Each time a flight takes-off, the list of flights waiting to take-off must be displayed.  Sequence of take-off is the sequence of addition to the waitlist

2168


Is c is a high level language?

238


Which is not valid in C a) class aClass{public:int x;}; b) /* A comment */ c) char x=12;

255


Explain what is a program flowchart and explain how does it help in writing a program?

265


How many loops are there in c?

228


What is binary tree in c?

254


i have to apply for rbi before that i need to know the the syllabus for the entrance questions. whethet it may be aps or techinical

1364


Device an algorithm for weiler-atherton polygon clipping, where the clipping window can be any specified polygon

4941