Skip to content

Instantly share code, notes, and snippets.


Block or report user

Report or block ChuckZhu

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
ChuckZhu / gist:be8cfdef6a8fae49c7b07023d31ccfd0
Created Nov 24, 2017
#1. 有1、2、3、4个数字,能组成多少个互不相同且无重复数字的三位数?都是多少?
View gist:be8cfdef6a8fae49c7b07023d31ccfd0
count = 0
for i in range(1,5):
for j in range(1,5):
for k in range(1,5):
if (i != j) and (j != k) and (i != k):
count += 1
print i,j,k
print ("There are " + str(count) + " different combinations")
You can’t perform that action at this time.