Solve problem "Series - 2" online - Learn Python 3 - Snakify

Problem «Series - 2» (Easy)


Statement

Given two integers A and B. Print all numbers from A to B inclusively, in increasing order, if A < B, or in decreasing order, if A ≥ B.

In all the problems input the data using input() and print the result using print().



Saved solutions

Tests

Input Correct answer Result
1
10
1 2 3 4 5 6 7 8 9 10
10
1
10 9 8 7 6 5 4 3 2 1
179
179
179
-14
7
-14 -13 -12 -11 -10 -9 -8 -7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7
12
-5
12 11 10 9 8 7 6 5 4 3 2 1 0 -1 -2 -3 -4 -5
-3
-7
-3 -4 -5 -6 -7