#!/usr/bin/env python

 import glob
import os
os.chdir(“./”)
for file in glob.glob(“*.py”):
print file

print “#######Another One##########”

import os
for file in os.listdir(“./”):
if file.endswith(“.py”):
print file

print “#######Another Two##########”

import os
for root, dirs, files in os.walk(“./”):
  for file in files:
    if file.endswith(“.py”):
      print os.path.join(root, file)

print “#######Another Three##########”

import os
import glob
os.chdir(“./”)
filename_arr={}
i=0
for files in glob.glob(“*.py”):
filename_arr[i] = files
i += 1
for key, value in filename_arr.items():
print key, value

最新文章

  1. PHP storm快捷键
  2. SQL查询表字段的信息
  3. nginx基于IP的虚拟主机
  4. AndroidStudio 中的坑Error:(1, 0) Plugin is too old, please update to a more recent version, or set ANDROID_DAILY_OVERRID
  5. SpringMVC接收参数的注解笔记
  6. ACCESS 数据库使用配置调整解决方案
  7. SharedPreferences详解
  8. JavaWeb项目开发案例精粹-第6章报价管理系统-05Action层
  9. CSS居中的方法整合--水平居中
  10. iOS动画原理
  11. [OC Foundation框架 - 7] NSArray的创建与遍历
  12. 从源码编译rpi的内核
  13. Discuz论坛下载与安装
  14. OC可变參数的函数实现va_start、va_end、va_list的使用
  15. mvn profile 深层次目录打参数核心配置
  16. 收藏的一些javascript片段
  17. 3407: [Usaco2009 Oct]Bessie's Weight Problem 贝茜的体重问题
  18. IDEA右侧 Maven oracle依赖包有红色波浪线
  19. Sudoku 小项目
  20. 论文阅读笔记三十四:DSSD: Deconvolutiona lSingle Shot Detector(CVPR2017)

热门文章

  1. Hibernate3.3用户手册摘要-1-辅助类,session
  2. Load an X509 PEM file into Windows CryptoApi
  3. 安卓集成发布详解(二)gradle
  4. iframe获取父、子窗口的方法
  5. Expecting "jsp:param" standard action with "name" and "value" attributes错误
  6. 242. Valid Anagram
  7. 值得推荐的C/C++框架和库 (真的很强大)
  8. POJ 2411 Mondriaan'sDream(状压DP)
  9. c#(特殊集合)
  10. redis 安装并设置为开机启动服务