File tree 2 files changed +4
-10
lines changed
Python_stdin_data_structures/list
2 files changed +4
-10
lines changed Original file line number Diff line number Diff line change 4
4
"""
5
5
列表操作及性能测试
6
6
"""
7
- import pathlib
8
- import sys
7
+
9
8
import timeit
10
9
11
- util_p = pathlib .Path ('../..' ).resolve ()
12
- sys .path .append (str (util_p ))
13
10
from util import utils
14
11
15
12
Original file line number Diff line number Diff line change 1
1
#!/usr/bin/env python
2
2
# -*- coding: utf-8 -*-
3
3
# Created by imoyao at 2019/6/10 18:34
4
- import pathlib
5
- import sys
6
4
7
- util_p = pathlib .Path ('../' ).resolve ()
8
- sys .path .append (str (util_p ))
9
- from queue import Queue
10
5
6
+ from Queue .queue import Queue
11
7
12
- def hot_potato (name_lists , num ): # TODO:待验证
8
+
9
+ def hot_potato (name_lists , num ): # TODO:待验证
13
10
"""
14
11
假设拿着土豆的孩子位于队首,当开始传递土豆时,模拟器会将那个孩子从队首移出队列然后立即让他从队尾进入队列。所有在他前面的人都
15
12
轮过一遍后才会再次轮到他传土豆。每经过'num'次出队入队的过程后,站在队首的孩子就会永久离开队列,游戏将在新的圆圈中继续进行。
You can’t perform that action at this time.
0 commit comments