Assignment 1

6. Determine the product of two input numbers without using multiplication

CPE102L
1Q1819
start

ctr=1
product=0

input num1
input num2

if(num<0 and num2<0)
	num1=num1*-1
	num2=num2*-1
elseif(num1>num2)
	temp=num1
	num1=num2
	num2=temp
endif

while(ctr<=num2)
	product=product+num1
	ctr++
endwhile

print product

end