Write a python program to input a number and print its first five multiples
Answers
Answered by
1
Answer:
>>> max_num = 100. >>> multiples = [1] + [5 * i for i in range(-max_num, max_num)][max_num + 1:max_num + 20] + [max_num] >>> print(multiples)
...
res = [i for i in range(5, 101, 5)]
print(*res)
If you want 1 to be included for some unknown reasons, do the following and then print.
res.insert(0,1)
hope you are having a good day ❤️ ✌️
Similar questions
English,
2 months ago
Hindi,
2 months ago
Social Sciences,
2 months ago
Biology,
5 months ago
Computer Science,
5 months ago
Biology,
9 months ago
French,
9 months ago