Notice
														
												
											
												
												
													Recent Posts
													
											
												
												
													Recent Comments
													
											
												
												
													Link
													
											
									| 일 | 월 | 화 | 수 | 목 | 금 | 토 | 
|---|---|---|---|---|---|---|
| 1 | 2 | 3 | 4 | |||
| 5 | 6 | 7 | 8 | 9 | 10 | 11 | 
| 12 | 13 | 14 | 15 | 16 | 17 | 18 | 
| 19 | 20 | 21 | 22 | 23 | 24 | 25 | 
| 26 | 27 | 28 | 29 | 30 | 31 | 
													Tags
													
											
												
												- PER
- python
- GIT
- tensorflow
- ASP
- mssql
- ubuntu
- Excel
- javascript
- MySQL
- sqlite
- 함수
- 유니티
- MS-SQL
- 리눅스
- 라즈베리파이
- port
- IOS
- flutter
- swift
- Linux
- PyQt
- PyQt5
- Unity
- 맛집
- pandas
- urllib
- 날짜
- node.js
- 다이어트
													Archives
													
											
											
											
											목록os.path.splitext(f)[1].lower() (1)
아미(아름다운미소)
			
			
				Python directory search and counting by specific extensions
				
	
	
               
           
					
					
					
					
					
					
						
					
				python 디렉토리 전체탐색후 특정확장자별로 카운트하기 # -*- coding: utf-8 -*- ''' Created on 2018. 9. 5. @author: bhm ''' import os from datetime import datetime class CGetAllFiles : def __init__( self ) : pass def getFiles( self , recdir ): x = 0 y = 0 for pack in os.walk(recdir): for f in pack[2]: if os.path.splitext(f)[1].lower() =='.wav': x += 1 if os.path.splitext(f)[1].lower() =='.mp3': y += 1 print ( ("Dir: %s..
				랭귀지/python
				
				2018. 9. 8. 11:00