https://www.python-course.eu/python3_list_manipulation.php 模拟超市购物 shopping_list = [ 'milk' , 'yoghurt' , 'egg' , 'butter' , 'bread' , 'bananas' ] cart = [ ] while shopping_list != [ ] : article = shopping_list. pop ( ) cart. append ( article ) print ( article , shopping_list , cart ) print ( "shopping_list: " , shopping_list ) print ( "cart: " , cart ) letter salad s = "Toronto is the largest City in Canada" t = "Python courses in Toronto by Bodenseo" # print(list(zip(s,t))) ss = "" . join ( [ "" . join ( x ) for x in zip ( s , t ) ] ) print ( ss ) #TPoyrtohnotno ciosu rtshees lianr gTeosrto nCtiot yb yi nB oCdaennasdeao print ( ss [ :: 2 ] ) #Toronto is the largest City in Canada print ( ss [ 1 :: 2 ] ) #Python courses in Toronto by Bodenseo 重复的陷阱 x = [ "a" , "b" , "c" ] y = [ x ] * 4 print ( y ) # [[...