devmingle
Home
Categories
Popular Codes
Articles
/
Python
/
Os
Os
Os
LINUX !!!!
0
Os
import os total_size = 0 start_path = '.' # To get size of current directory for path, dirs, files in os.walk(start_path): for f in files: fp = os.path.join(path, f) total_size += os.path.getsize(fp) print("Directory size: " + str(total_size))
0
Source:
tutorialspoint.com
Share
Similar codes
0 vote
94 views
2 answers
Plt axis tick color
Python
0 vote
104 views
1 answer
How to input a string in streamlit
Python
3 votes
86 views
1 answer
Datetime.timedelta months
Python
0 vote
93 views
1 answer
Python string: index error
Python
58 votes
39 views
1 answer
Case in pyhton
Python
0 vote
139 views
1 answer
Python randomly chose user agent
Python
-2 votes
78 views
1 answer
No connection could be made because the target machine actively refused it python
Python
0 vote
91 views
1 answer
How to get all values from class in python
Python
0 vote
91 views
1 answer
Python import specific excel sheet
Python
0 vote
83 views
1 answer
Find highest value in array python
Python
Share