Re: [Tutor] Question about a python finction

2018-05-12 Thread Alan Gauld via Tutor
On 12/05/18 06:40, peter wrote: > range does not work the same for 2.7 and my 3.6.5. Seems they have > changed the nature of range. It is a built in listed along with lists > and tuples You are correct in that it has changed slightly and now returns a range object. but you can convert it to a

Re: [Tutor] Question about a python finction

2018-05-12 Thread peter
range does not work the same for 2.7 and my 3.6.5. Seems they have changed the nature of range. It is a built in listed along with lists and tuples list(range(10)) [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] >>> tuple(range(10)) (0, 1, 2, 3, 4, 5, 6, 7, 8, 9) seems they have changed range for

Re: [Tutor] Question about a python finction

2018-05-11 Thread David Rock
> On May 9, 2018, at 07:14, kevin hulshof 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,

Re: [Tutor] Question about a python finction

2018-05-11 Thread Mark Lawrence
On 09/05/18 13:14, kevin hulshof 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] Thank you for you’re time Seems like 'range' should fit your needs

[Tutor] Question about a python finction

2018-05-11 Thread kevin hulshof
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] Thank you for you’re time Sent from my iPhone ___ Tutor maillist - Tutor@python.org To