Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
python permutations
import itertools r=0 rr=0 for pm in itertools.permutations([1,2,3,4,5,6,7,8]): if (pm[4]!=pm[5]-1):continue if (pm[6]!=pm[7]-1):continue if (pm[6]<5):continue if (pm[0]==8):continue if (pm[3]==1 or pm[4]==1):continue r+=1 if (pm[4]==4): rr+=1 print(r,r-rr)
run
|
edit
|
history
|
help
0
on_off
Python examples - SIMPLE
PyDicCom
PyStr
GayChicken
Problem: fb_series
python2 - division - 0
PyRangeArg
PyMap
project euler 16