Use zip(*a)
:
>>> zip(*a)
[(1, 4, 7), (2, 5, 8), (3, 6, 9)]
How it works: zip(*a) is equal to zip(a[0], a[1], a[2]).
More Related Contents:
- Tkinter understanding mainloop
- Loop through all nested dictionary values?
- python list by value not by reference [duplicate]
- How do I create a list of random numbers without duplicates?
- I can’t install pyaudio on Windows? How to solve “error: Microsoft Visual C++ 14.0 is required.”?
- Creating a dynamic choice field
- Read file from line 2 or skip header row
- Python Image Library fails with message “decoder JPEG not available” – PIL
- What are some good Python ORM solutions? [closed]
- How to move pandas data from index to column after multiple groupby
- How to divide flask app into multiple py files?
- Add an element in each dictionary of a list (list comprehension)
- Block tridiagonal matrix python
- How to create Python egg file
- PyQt QListWidget custom items
- Deal with overflow in exp using numpy
- Flask-SQLAlchemy db.create_all() raises RuntimeError working outside of application context
- Mocking async call in python 3.5
- Can not increment global variable from function in python [duplicate]
- Get a unique list of items that occur more than once in a list
- Python native coroutines and send()
- Python: setting two variable values separated by a comma in python
- Unable to import path from django.urls
- Can I get a return value from multiprocessing.Process?
- Got continuous is not supported error in RandomForestRegressor
- Simple cross import in python
- Selenium Python – Finding Elements by Class Name With Spaces
- Move and zoom a tkinter canvas with mouse
- Static media images are not displaying in Django
- How to handle IncompleteRead: in python