From 3f99835f559b1cd73537e95d3974404dcaf11fb9 Mon Sep 17 00:00:00 2001 From: anyin233 Date: Mon, 15 Jun 2020 10:36:59 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=8C=E6=88=90=E7=AC=AC=E5=9B=9B=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- slice_use.py | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 slice_use.py diff --git a/slice_use.py b/slice_use.py new file mode 100644 index 0000000..90e24f6 --- /dev/null +++ b/slice_use.py @@ -0,0 +1,6 @@ +import random + +li = [random.randint(0, 65535) for _ in range(100)] +print(li[:]) +print(li[::-1]) +print(li[::2]) \ No newline at end of file