February 5, 2011

C Program for Multiplication without Using Multiply Operator *

Here is another program from the series tricky code. Here I am going to show you how we can do Multiplication without using Multiply Operator *. Programs like this you will rarely get anywhere else.

Comment below to express your feeling  and suggest me new idea for more tricky code.

Logic of the code:

First you give a try to think the logic.

Here is the answer,

Let a and b are two variables then c=axb. We take 9 as a and 8 as b then c=72.

In other word we are adding 9, 8 times or adding 9, 8 times,  so simple logic. This is what I converted into programing.


//C Program for Multiplication without Using Multiply Operator *
void main()
int n,m,s=0;
printf("\nEnter the values");
printf("Result = %d",s);

Also read

C Program to Print HELLO without HELLO

Hope you liked my posts, give comments if you have any doubts.. :)

Related Posts :

Categories: ,


a 100 thanks to your first line! thankfully i wanted to follow the steps and it made me think:D:)!

Post a Comment

Twitter Delicious Facebook Digg Stumbleupon Favorites More

Related Posts with Thumbnails