permutation tag

2 questions


1 answers
51 views
0
To obtain all possible permutations from a list

How do we find all possible permutations as elements of the list?For example, permutations([1, 2]) ->[1, 2][2, 1]permutations([1, 2, 3]) ->[1, 2, 3][1, 3, 2][2, 1, 3][2, 3, 1][3, 1, 2][3, 2, 1]W...


1 answers
49 views
0
Question to put 2D array variables... (I want to code it so that it doesn't overlap!)

Hello! I'm Python beginner.The value of n,s,t,k as a variable in an array such as a n : 20~28/s,t,k : 20~27 I calculated the number of all cases and printed it out with a txt file called Noutput using...

2 years ago

© 2024 OneMinuteCode. All rights reserved.