# Find the Sum of the series: 1+1/2+1/3..+ 1/N in Python

In this, you will learn how to write a Python program to find the Sum of the series: 1 + 1/2 + 1/3 +… .. + 1 / N.

#### Steps

1. Take the number of terms to find the sum of the series.

2. Sum is initialized to zero.

3. Use a for loop to find the sum of the series and increment number by one at every iteration.

4. Print the whole series after rounding it to three decimal places.

5. Exit.

### Let's take a look at the code how to find the sum of series in Python Programming.

Python Code:

`n = int(input("enter number of terms:"))a = []sum = 0for i in range(0,n):    i = i+1    x = str(1) + '/' + str(i)    sum = sum + (1/i)    a.append(x)print(a)print('sum of series is:',round(sum,3))`
`Output:`
```enter number of terms:7
['1/1', '1/2', '1/3', '1/4', '1/5', '1/6', '1/7']
sum of series is: 2.593```

`Recommended Post:Python Program to check vowel or ConsonantProgram to check character is alphabet or not in PythonPython to check whether the year is leap or notPython to check if number is Positive, Negative or 0Python Program to solve Quadratic equationProgram to generate Random numbers in PythonProgram to swap two numbers in PythonProgram to Add two numbers in PythonPython to convert decimal to binary, octal and hexadecimalPython Program to find large number among three numbers`