ianthe

使用Python:
1. 分析日志,尤其是服务器端日志。脚本就是短小精悍的
2. 用来生成测试数据,比如生成随机的10w个词,很麻烦;如果找一个字库,存在数表里,然后用Python取数据
3. 做数据发出的程序。比如用Python发tcp、udp
4. 写多线程。
5. 开发很少,主要是写脚本语言

 

网上找的,凌乱堆砌先

#This is the python test
import urllib;
print "Program is working............";
fileName="网址";
fileHandle=urllib.urlopen(fileName);
fileData=fileHandle.read();
fileHandle.close();
for tempLine in fileData:
print tempLine,;
print "Program is over!";



在python中如何在使用了print后不自动换行啊?

sys.stdout.write不自带自动换行,一次输出一个字符串。

Python 2:使用print后加一个逗号:print \'hello\',

分类:

技术点:

相关文章:

  • 2021-10-02
  • 2021-11-20
  • 2021-12-25
  • 2022-12-23
  • 2021-06-06
  • 2021-11-29
  • 2021-05-19
猜你喜欢
  • 2021-12-09
  • 2022-12-23
  • 2021-09-24
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案