Write a Java program to multiply N numbers without using * operator

By | March 10, 2017

Java program to multiply N numbers without using * operator


Write a Java program to multiply N numbers without using * multiplication operator.As we all know that there are lot of methods or techniques to solve problem to produce desired output.

Basic idea of this java program to show varies methods of problem solving techniques, although we have standard operator ” * ”  to perform the basic operation of multiplication.

Our aim is to do that without using ” * ”   operator we will show you multiplication operation on integer but you can extend it to your aspect of need.

In this program, first we input N integers from the user and store them into an Array.Then we make iterations inside loop and add the previous element k times to the Current element to produce desired output.

Here, below is the source code of Java Program to multiply N numbers without using * multiplication operator which is successfully compiled and run(Netbeans) on the Windows System to produce particular output.Let’s look at the program below.


SOURCE CODE : :


 

 


OUTPUT : :


 

Leave a Reply