Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

difference between iglob() and glob() functions in python

import glob
# path of the current directory
path = './Rough'
htmlfilesusing_glob = glob.glob(path + '/*.html')
print(htmlfilesusing_glob)


htmlfilesusing_iglob = glob.iglob(path + '/*.html')
print(htmlfilesusing_iglob)

# output
# ['./Roughhtml.html', './Roughindex.html']
# <generator object _iglob at 0x0000018A0F54A030>
    Copy Code
Comment

PREVIOUS NEXT
Code Example
Python :: install python 3.10 pip 
Python :: build numpy array 
Python :: python new set 
Python :: move python file 
Python :: find a paragraph in requests-html 
Python :: keyword only arguments python 
Python :: Python NumPy atleast_3d Function Example when inputs are high dimesion 
Python :: Python NumPy moveaxis function Example 02 
Python :: in django drowpdown list shown in database tables 
Python :: manipulate sns legend 
Python :: Python3: Deleting even and only showing uneven numbers from, set list. 
Python :: Python NumPy asarray_chkfinite Function Example Tuple to an array 
Python :: Python NumPy row_stack Function Example with 1d array 
Python :: configure socketio static file python specific content type 
Python :: como saber si un string es un numero python 
Python :: Python __sub__ magic method 
Python :: NumPy rot90 Syntax 
Python :: beaglebone install python 3.7 
Python :: NumPy binary_repr Syntax 
Python :: qt list widget let editable 
Python :: adjugate of 3x3 matrix in python 
Python :: call a Python range() using range(start, stop) 
Python :: parameter name in string 
Python :: find smallest element not present in list python 
Python :: matrix implement 
Python :: python list len 
Python :: pandas drop zeros from series 
Python :: EDA dataframe get missing and zero values 
Python :: ring Search List Item 
Python :: nnumpy matrix count non negative values 
ADD CONTENT
Topic
Content
Source link
Name
1+5 =