Question d’entretien chez PTC

Write a program to print the series.