From ae9cd7976fbea4a2dc0fb44562dd4738a4c193f0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AD=9F=E5=9C=A3=E5=A5=87?= <9705900+meng-shengqi@user.noreply.gitee.com> Date: Sat, 18 Sep 2021 15:00:31 +0000 Subject: [PATCH] add homework_01_python/002.py. --- homework_01_python/002.py | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 homework_01_python/002.py diff --git a/homework_01_python/002.py b/homework_01_python/002.py new file mode 100644 index 0000000..a003b51 --- /dev/null +++ b/homework_01_python/002.py @@ -0,0 +1,9 @@ +i=0 +print("有以下三位数:") +for a in range(1,5,1): + for b in range(1,5,1): + for c in range(1,5,1): + if a!=b and b!=c and a!=c: + i=i+1 + print(a*100+b*10+c) +print("共",i,"个") \ No newline at end of file -- Gitee