Computer Science, asked by usksss847, 9 months ago

help me please please please please please please please please please please please please please please please​

Attachments:

Answers

Answered by bhattak9617
0

import java.util.*;

class series

{

double series (double n)

{

double sum ;

for ( double i = 1.0 ; i <= n ; i++)

{

sum = sum + 1 / i;

}

return sum;

}

double series (double a, double n)

{

double sum;

int k = 1;

for (double i = 1 ; i<=n ; i++)

{

sum = sum + k / Math.pow(ay,(k+1));

k = k + 3;

}

return sum;

}

public static void main()

{

Scanner sc = new Scanner(System.in)

System.out.println("Enter value of 'a' ");

double a1 = sc.nextDouble();

System.out.println("Enter value of 'n' ");

double n1 = sc.nextDouble();

double series1;

series1 = series(n1);

System.out.println("Sum of 1st series is :"+series1);

double series2;

series2 = series(a1,n1);

System.out.println("Sum of 2nd series is :" +series2);

}

}

HOPE IT HELPS !!

MARK BRAINLIEST !!

Answered by genius1947
0

Answer:

Galileo di Vincenzo Bonaiuti de' Galilei was an Italian astronomer, physicist and engineer, sometimes described as a polymath, from Pisa. Galileo has been called the "father of observational astronomy", the "father of modern physics", the "father of the scientific method", and the "father of modern science". 

Explanation:

Galileo di Vincenzo Bonaiuti de' Galilei was an Italian astronomer, physicist and engineer, sometimes described as a polymath, from Pisa. Galileo has been called the "father of observational astronomy", the "father of modern physics", the "father of the scientific method", and the "father of modern science". 

Similar questions