CS作业代写 程序 代码、金融、统计、物理、数学、EE、论文、essay案例

  • # 将两个字典合并 #!/usr/bin/python def adddict(dict1,dict2): xin = {} for key in dict1.keys(): xin[key] = dict1[key] for key in dict2.keys(): xin[key] = dict2[key] return xin s1 = {1:222,’c’:’d’,’e’:’f’} s2 = {2:333,’g’:’h’,’i’:’j’} print adddict(s1,s2) 标签: … 继续阅读“python 合并字典”

    :
  • 这是一个简单的网络程序,可以用来扫描指定ip的常用端口 from socket import * tgtHost=raw_input("What is the web address?: ") tgtPorts=raw_input("What are the ports seperated by commas? or would you like to test all?: ") def connScan(tgtHost, tgtPort): try: c … 继续阅读“python端口扫描程序”

    :