Display Items in Python List
Today, I was asked to write a small python code to print out all items in a list with comma seperated. The last item would end the with a ‘dot’, or full stop. For example, here is a list of sports: sports = [ 'basketball', 'soccer', 'netball' ] And I was asked to print out the expected output: My favourite sports are: basketball, soccer, netball. But how do I do this? Today, I’ll be showing you how to show the expected output using join and without join. ...