I have this code::

name_list=[]            

name1=print(input("what is your name: "))

name_list.append(name1)

print(name_list)

it returns
Jon
[NONE]

If i input a name jon.

Why does it not append to list please?

Recommended Answers

All 2 Replies

get rid of "print(input(..."
name1=input("what is your name: ")

commented: indeed +14

Cheers for that... Im such an idiot!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.