Okay, I understand now. Thanks!
Ken
Steve Willoughby wrote:
On Thu, Mar 11, 2010 at 10:32:45AM -0500, Ken G. wrote:
list = ['physics', 'chemistry', 1997, 2000]
This is a list of 4 elements, and lists allow elements to
be changed, so
list[2] = 2010
Will change the v
Okay, now, it is understood. Thanks.
Ken
Andre Engels wrote:
On Thu, Mar 11, 2010 at 4:32 PM, Ken G. wrote:
If the following program change list[2] to 2010, replacing 1997 (and it
does), why doesn't the second program work in changing line[ 9:11] to 20
from 08?
FIRST PROGRAM:
list = ['
On Thu, Mar 11, 2010 at 10:32:45AM -0500, Ken G. wrote:
>list = ['physics', 'chemistry', 1997, 2000]
This is a list of 4 elements, and lists allow elements to
be changed, so
>list[2] = 2010
Will change the value of list to be ['physics','chemistry',1997,2010]
>line = [20100208208411
On Thu, Mar 11, 2010 at 4:32 PM, Ken G. wrote:
> If the following program change list[2] to 2010, replacing 1997 (and it
> does), why doesn't the second program work in changing line[ 9:11] to 20
> from 08?
> FIRST PROGRAM:
>
> list = ['physics', 'chemistry', 1997, 2000]
> print list[2]
> li
If the following program change list[2] to 2010, replacing 1997 (and it
does), why doesn't the second program work in changing line[ 9:11] to 20
from 08?
FIRST PROGRAM:
list = ['physics', 'chemistry', 1997, 2000]
print list[2]
list[2] = 2010
print list[2]
OUTPUT:
1997
2010