Python Forum
Program to print: Last Name, ID, Mobile Number, All - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: Homework (https://python-forum.io/forum-9.html)
+--- Thread: Program to print: Last Name, ID, Mobile Number, All (/thread-2187.html)

Pages: 1 2


RE: Program to print: Last Name, ID, Mobile Number, All - panick1992 - Feb-24-2017

I completely understand. but can you give me some guidance on how to declare the variable I am asking please and then I will continue from there to complete the code and post it over here for feedback :)


RE: Program to print: Last Name, ID, Mobile Number, All - Larz60+ - Feb-24-2017

personal_details = input('Enter personal_details')



RE: Program to print: Last Name, ID, Mobile Number, All - panick1992 - Feb-24-2017

That is fantastic micseydel. I will look into the tutorials and then post here any question that might be needed an answer from a more experience user than me


RE: Program to print: Last Name, ID, Mobile Number, All - Ofnuts - Feb-24-2017

Hints: you can use the split() function to chop a long string into parts, using a delimiter. So for instance you can split once with a ;, and then split each part with :. You can keep these parts (name, phone...) together in a tuple that you add to a list. When you are asked about some person, you scan the list and find the tuple that contains the right name and print its elements.


RE: Program to print: Last Name, ID, Mobile Number, All - panick1992 - Mar-15-2017

Thank you very much for your help guys