P-99: 1.25 Generate a random permutation of the elements of a list
P-99: Ninety-Nine Prolog Problemsの問題にMercuryで解答していきます.
["f", "e", "a", "c", "b", "d"]
P-99: 1.24 Lotto: Draw N different random numbers from the set 1..M
P-99: Ninety-Nine Prolog Problemsの問題にMercuryで解答していきます.
[3, 14, 25, 42, 17, 49]
P-99: 1.23 Extract a given number of randomly selected elements from a list
P-99: Ninety-Nine Prolog Problemsの問題にMercuryで解答していきます.
["e", "h", "f"]
P-99: 1.22 Create a list containing all integers within a given range
P-99: Ninety-Nine Prolog Problemsの問題にMercuryで解答していきます.
[4, 5, 6, 7, 8, 9]
P-99: 1.21 Insert an element at a given position into a list
P-99: Ninety-Nine Prolog Problemsの問題にMercuryで解答していきます.
["a", "alfa", "b", "c", "d"]
P-99: 1.20 Remove the K'th element from a list
P-99: Ninety-Nine Prolog Problemsの問題にMercuryで解答していきます.
b ["a", "c", "d"]
P-99: 1.19 Rotate a list N places to the left
P-99: Ninety-Nine Prolog Problemsの問題にMercuryで解答していきます.
["d", "e", "f", "g", "h", "a", "b", "c"] ["g", "h", "a", "b", "c", "d", "e", "f"]