20
ファロは配列をシャッフルする
A ファロshuffleが頻繁に「シャッフル」デッキにマジシャンで使用される技術です。ファロシャッフルを実行するには、まずデッキを2つの等しい半分にカットしてから、2つの半分をインターリーブします。例えば [1 2 3 4 5 6 7 8] シャローファロは [1 5 2 6 3 7 4 8] これは何回でも繰り返すことができます。興味深いことに、これを十分な回数繰り返すと、常に元の配列に戻ります。例えば: [1 2 3 4 5 6 7 8] [1 5 2 6 3 7 4 8] [1 3 5 7 2 4 6 8] [1 2 3 4 5 6 …
31
code-golf
permutations
card-games
code-golf
graphical-output
random
code-golf
image-processing
color
code-golf
primes
code-golf
math
arithmetic
combinatorics
decision-problem
code-golf
sequence
number-theory
binary
code-golf
number-theory
set-theory
code-golf
hashing
code-golf
game
card-games
code-golf
ascii-art
code-golf
arithmetic
array-manipulation
jelly
code-golf
string
array-manipulation
code-golf
sorting
code-challenge
code-golf
number
date
binary
code-golf
arithmetic
code-golf
math
number
linear-algebra
polynomials
code-golf
ascii-art
code-golf
grid
decision-problem
code-golf
string
combinatorics
code-golf
string
kolmogorov-complexity
arithmetic
date
code-golf
number
data-structures
code-golf
ascii-art
kolmogorov-complexity
code-golf
string
ascii-art
code-golf
ascii-art
kolmogorov-complexity
code-golf
array-manipulation