Created
February 7, 2020 08:21
-
-
Save wiccy46/3b6729e09e77e0e9e59c602370f95a22 to your computer and use it in GitHub Desktop.
[conversion] A collection of python conversion #python
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # List of string to a long string. | |
| alist = ['1', '2', '3', '4'] | |
| alist_joint = ' '.join(alist) | |
| # Long string to list | |
| astring = '1 2 3 4' | |
| alist = astring.split(sep=' ') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment