program to get the remainder and quotant of given two
numbers with out using % and / operators?
Answer Posted / y hussain reddy
void main()
{
int a,b;
int c=0;
printf("nter a,b");
scanf("%d %d ",&a,&b);
while(a>=b)
{ c++;
a=a-b;
}
printf("a/b=%d",c);
printf("a%b=%d",a);
}
| Is This Answer Correct ? | 12 Yes | 7 No |
Post New Answer View All Answers
What is abstract data structure in c?
Can include files be nested?
To print the pattern 1 2 3 4 5 10 17 18 19 6 15 24 25 20 7 14 23 22 21 8 13 12 11 10 9
What are the key features in c programming language?
What are the scope of static variables?
Write a program to print “hello world” without using semicolon?
main() { struct s1 { char *str; struct s1 *ptr; }; static struct s1 arr[] = { {"Hyderabad",arr+1}, {"Bangalore",arr+2}, {"Delhi",arr} }; struct s1 *p[3]; int i; < BR> for(i=0;i<=2;i++) p[i] = arr[i].ptr; printf("%s ",(*p)->str); printf("%s ",(++*p)->str); printf("%s ",((*p)++)->str); }
What is the difference between text and binary i/o?
Device an algorithm for weiler-atherton polygon clipping, where the clipping window can be any specified polygon
What is enumerated data type in c?
What is huge pointer in c?
Can you subtract pointers from each other? Why would you?
Which driver is a pure java driver
Can a function argument have default value?
What is the difference between break and continue?