Copying List Elements To Another List And Changing Them I'm a beginner python programmer..I recently started reading a python book called: "Python Crash Course, 2nd Edition: A Hands-On, Project-Based Introduction to Programming"...And I found an interesting challenge...The  challenge is to copy the elements of the list to another list and change the elements to make them become lowercase...I solved the challenge by myself and wrote two versions for it...

Here is my first attempt:

#Method1: Using the slice method
currentUsers = ['MrSplash', 'MrRobot', 'Peter1234', 'Steve', 'James']
newUsers = ['Davidpeterson', 'Elliot345', 'STEVE', 'mrRobOt', 'NickB3ns0N']

currentUsersLower = currentUsers[:]
for i in range(0, 5):
    currentUsersLower[i] = currentUsersLower[i].lower()


And here is my second attempt:

#Method2: Using a normal for loop
currentUsers = ['MrSplash', 'MrRobot', 'Peter1234', 'Steve', 'James']
newUsers = ['Davidpeterson', 'Elliot345', 'STEVE', 'mrRobOt', 'NickB3ns0N']

currentUsersLower = []
for user in currentUsers:
    currentUsersLower.append(user.lower())


My first question is this: Imagine we are working with around a million elements here. Which of these methods is efficient?

I define efficient as:


Easy to maintain and read
Performance-wise(Because let's face it, a million elements requires a lot of performance here)


My second question is this: Are there better ways to do this task than the ones I presented here? 
If so please share them as an answer here

Note: The code works on both Python 3 and 2.
Your second version is better than your first version, for two reasons:


All else being equal, building a new list is IMO easier to reason about than changing a list you're iterating over.
You're iterating using for...in rather than iterating by index using a range (and the range in your first example is hardcoded rather than being over the len of the list, which is doubly bad).


The most efficient/pythonic way is to use the comprehension syntax:

currentUsersLower = [user.lower() for user in currentUsers]


(Also, standard Python style would be to name these current_users and current_users_lower!)