Help me in completing this code

give me some clues to complete this problem.

hello @tarunasree123
just use while loop,keep generating next term of the series till the number of required terms are less than n1.