[Tutor] Question about a python finction
David Rock
david at graniteweb.com
Fri May 11 18:58:44 EDT 2018
> On May 9, 2018, at 07:14, kevin hulshof <kevinhulshof at live.nl> wrote:
>
> Hello,
>
> Is there a function that allows you to grab the numbers between two numbers?
>
> Eg. If you input the numbers 1 and 4
> To make a list like this [1,2,3,4]
One option is range
range(1,5)
>>> range(1,5)
[1, 2, 3, 4]
https://docs.python.org/2/library/functions.html#range
—
David Rock
david at graniteweb.com
More information about the Tutor
mailing list