Printing each items in list (nested or not) on new line with or without required tab spaces and the data will be sent to the required file or output screen depending on the file object argument
Project description
- This function takes a positional arguments called "the_list","indent" and "level", 'the_list' is any Python list (of - possibly - nested lists). Each data item in the provided list is (recursively) printed to the screen on it's own line.
- A second argument 'indent' is set to default value 'False', which means indentation or tab-stops are not required by default. If user wants to add indentation while printing the nested list it should be set to 'True'.
- A Third argument 'level' is used to insert required number of tab_stops when nested list is encountered.
- Fourth argument 'fh' is used to specify where the output of this function should write (place to write your data to), a default value of this argument is sys.stdout so that it continues to write to the screen if no file object is specified when the function is invoked.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Close
Hashes for nester_with_fileObject-1.0.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1cd525b3ed256a57011ed83b879e3224e57aa60e59b71f1046c92e474375a366 |
|
MD5 | 22ba82a16c13dfbb3351b191dd6fc822 |
|
BLAKE2b-256 | e698dfbbd2759047309f4acaf58bde75c70d45d7b8cbd1f871d5a8ff3bad4648 |
Close
Hashes for nester_with_fileObject-1.0.0-py3.10.egg
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4a1fecca00e984f2585b4c2547120a7e72b77be8fd149056e8c3d6a525a9e83b |
|
MD5 | f545ddce76fccfbfa69bd8d629565384 |
|
BLAKE2b-256 | 010680eff5e4b024fc9f50d7218eb04e2e690c266113a43a755a9c3f333ab72b |
Close
Hashes for nester_with_fileObject-1.0.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c26824bf80852deee9b12c6941d3645729ed9a306cc7ae2877438cda4f791145 |
|
MD5 | 9ff9e3a89692c15a702a2a23c0acef6b |
|
BLAKE2b-256 | e1142f1438979e54326d3e76e3254e0abecdf0e0170c284af76cadf6030d2824 |