D
D
Danil Polyansky2019-02-10 19:45:29
C++ / C#
Danil Polyansky, 2019-02-10 19:45:29

How can I make the script output 4 numbers, then step back by 10 numbers, and then output 4 numbers again?

Let's say so, there are numbers from 1 to 100, how can I make it so that it displays 2, 3, 4, 5, retreats 10 numbers and displays 12, 13, etc.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
T
Tsiren Naimanov, 2016-07-30
@ImmortalCAT

Go to the menu along the following path
"Test" -\u003e "Testing window" and there you will need to run it
and the screen shows that you are just building the project

0
0xD34F, 2019-02-10
@danil_polyanskiy

print(list(filter(lambda n: n % 10 in (2, 3, 4, 5), range(100))))

or
or
print([m + n * 10 for n in range(10) for m in range(2, 6)])

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question