write a program for 7*8 = 56 ? without using * multiply
operator ? output = 56

Answer Posted / rama krishna sidhartha

Here is the logic.
void func()
{
int i;
int result = 0;
for(i = 0; i < 8; i++)
{
result = result + 7;
}
printf("%d",result);
}

Is This Answer Correct ?    8 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

how to count no of words,characters,lines in a paragraph.

3905


How do we declare variables in c?

567


Can a variable be both static and volatile in c?

606


How can you find the exact size of a data type in c?

601


Subtract Two Number Without Using Subtraction Operator

356






What are the preprocessor categories?

639


In C programming, what command or code can be used to determine if a number of odd or even?

622


What is the difference between typedef and #define?

545


What are the types of bitwise operator?

661


What are the different properties of variable number of arguments?

665


in ‘C’ language for Matrix Multiplication fails” Introspect the causes for its failure and write down the possible reasons for its failure.

7404


What is #pragma statements?

587


What is the difference between break and continue?

604


What is the difference between text files and binary files?

676


How do you use a 'Local Block'?

720