Javatpoint Logo

Summation by taking two inputs from user ?

By: waseem*** On: Sat May 05 13:35:46 IST 2018     Question Reputation0 Answer Reputation0 Quiz Belt Series Points0  0Blank User
How can i get summation result of two user given inputs where inputs will be -
1.double a1=2;
2.double b1=5;
3. double a2=5;
4. double b2 = 8;
The series of a and b should be iterated from input file.
and so on .
the summation should be as

double summation = summation+(a*b);
Up0Down