- #1
acurate
- 17
- 1
Homework Statement
My professor wants us to program on Python, where we have a certain sequence, for example:
sequence = ("one", "two", "three", "four")
I need to replace one of the sequence elements (example: "one") with another element (example: instead of the word "one", I need to put "zero").
2. The attempt at a solution
I really have no idea how to do it, but I guess I have to start with.
sequence = ("one", "two", "three", "four")
Do I need to use something like:
sequence [1 : : 2]
or something else?
Would really appreciate if you guys would help.
I would appreciate even a hint or advice on which path to take to be able to write this.