python二级备考(2) |
您所在的位置:网站首页 › 姓名性别年龄英文 › python二级备考(2) |
out.txt,其中有一些数据库操作功能的执行时间信息,如下所示: 示例 starting,0.000037,2.102 After opening tables,0.000008,0.455 System lock,0.000004,0.227 其中第1列是操作的名字,第2列是操作所花费的时间,单位是秒,第3列是操作时间占全部过程的百分比,字段之间用逗号','隔开。 读取out.txt文件里的内容,统计所有操作所花费的时间总和,并输出操作时间百分比最多的三个操作所占百分比的值,及其对应的操作名称,显示在屏幕上, 如下所示: . 示例 the total execute time is 0.001724 the top 0 percentage time is 46.023, spent in "Filling schema table" operation the top 1 percentage time is 36.932, spent in "Sending data" operation |
CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3 |