5.1 双 and
Originates from Pairs and Lists and extends to .
5.1.1 Naming Rules
Ideograph | Connotation | Elucidation | Example |
亻 as component | general derived set | Returns a new list with elements produced from the original input list. (Implies the input data and output data are the same type.) | |
阝 as component | serial subset | Returns a new list with elements serially produced from the input list.(Implies the input data and output data are the same type.) | |
as component | the rest part of the serial subset | Returns a new list with elements serially produced from the input list.(Implies the input data and output data are the same type.) | |
刂 as component | broken subset | Returns a new list with removing some elements from the input list. | |
as component | sectional sets | split the input list to sections or rearrange it to many related sets | |
function as input | Implies the type of input data is function. | ||
strengthen | Strengthen the process, thus the data of output may become longer, and the type may be changed accordingly. | ||
soften | Soften the process, thus the output data shorter. | ||
list as input | Implies the type of input data is list. | ||
boolean as output | Implies the type of output data is boolean. |
connotation : elment
originates from : 又
originally means : Right hand, borrowed as again in simplified chinese.
5.1.2 双, 㐅, , , 阴, 阳
Abstractly, we can pair two data together. Integrally, it is called 双. Separately, the position where set the first data is call 阳, the second is call 阴.
Further more, if we put another 双 to 阴 position of the former 双, we get a linked data. Likewise, the linked data can be extended as long as you want. By this way, if we leave 阴 of the ending 双 to be null(㐅), we get a data called ; if not, we call it .
Two human hand here stand for a data type with spaces of holding two data.The reaching from Left through Bottom to right 又 stands for multiple 双 linked head to tail; 㐅 means ending with empty(㐅).Has the similar function process as it resembles and the type of output is same as accordingly. Resembles except substituting 㐅 with 又, which means the ending position is not empty(㐅).Has the similar function process as it resembles and the type of output is same as accordingly.5.1.3 阴阳+-
Originally means sun in Chinese. Especially is borrowed to mean the former part of an object, or the positive part of an object in Ming. wiki.Originally Means moon, borrowed to mean the secondary part of of an object, or the negative part of an object in Ming. wiki.connotation : the first half part
originates from : 阳
originally means : sun, positive
: 阳 / 阴 + + / -
connotation : 阴 or 阳 nested in mutiple parenthesis reverse order
5.1.4 ,
> ( 1 2 3 4) '(1 2 3 4)
> ( '(1) '(2) '(3) '(4)) '(1 2 3 4)
> ( '(1) '(2 3 4) '(5 6) '(7)) '(1 2 3 4 5 6 7)
> ( '(a b) 'c) '(a b . c)
> ( '(a b) '(c . d)) '(a b c . d)
> ( '() 'a) 'a
> ( 'a) 'a
> ( 1 2 3 4) '(1 2 3 . 4)
> ( '(1) '(2) '(3) '(4)) '(1 2 3 . 4)
> ( '(1) '(2 3 4) '(5 6) '(7)) '(1 2 3 4 5 6 . 7)
> ( 1 2 3 '(4)) '(1 2 3 4)
> ( '(1) '(2) '(3) '((4))) '(1 2 3 4)
> ( '(1) '(2 22) '(3 33) '((4 44))) '(1 2 22 3 33 4 44)
> ( '(1) '(2 22) '((3 33)) '((4 44))) '(1 2 22 (3 33) 4 44)
> ( '(a b) '(c)) '(a b . c)
> ( '(a b) '((c . d))) '(a b c . d)
> ( '() '(a)) 'a
> ( '(a)) 'a
5.1.5 攸
🐘 𰁦 𢪛
5.1.6 , *
5.1.7 ,
5.1.8 弔, 弓,弓*, , *
connotation : refers a value from an specific index or position
originates from : 第
originally means : refer, rank
5.1.9 , , , , , , , , ,
5.1.10 末,
5.1.11 巨
🐘
> (巨 '(a b c d e 3 f g)) 8
5.1.12 ,, ,, ,, ,, ?
> ( '(a b c d e f g) 2) '(a b)
> ( '(a b c d e f g) 2) '(f g)
> ( '(a b c d e f g) 2) '(c d e f g)
> ( '(a b c d e f g) 2) '(a b c d e)
> ( '(a b c d e f g) 2)
'(a b)
'(c d e f g)
> ( '(a b c d e f g) 2)
'(a b c d e)
'(f g)
> ( '(8 4 a b 1 c d 2 e f g 3 5 9) 米?) '(8 4)
> ( '(8 4 a b 1 c d 2 e f g 3 5 9) 米?) '(8 4 a b 1 c d 2 e f g)
> (? '(a b) '(a b c d e f g)) #t
> (? '(a b z) '(a b c d e f g)) #f
5.1.13 , ,
5.1.14 𰂋,偏,,重、𠝤
connotation : insert between
originates from : 间
originally means : gap, interval, between
connotation : duplication
originates from : 重
originally means : heavy, deep, again, repeat, overlap
5.1.15 、𠆯
> ( '(21 3 888 666 55 77 1000)) '(1000 77 55 666 888 3 21)
> (𠆯 '(21 3 888 666 55 77 1000) <) '(3 21 55 77 666 888 1000)
> (𠆯 '(21 3 888 666 55 77 1000) >) '(1000 888 666 77 55 21 3)
> (𠆯 '("cat" "dog" "chicken" "duck" "fox") 句<?) '("cat" "chicken" "dog" "duck" "fox")
> (𠆯 '("cat" "dog" "chicken" "duck" "fox") 句>?) '("fox" "duck" "dog" "chicken" "cat")
5.1.16 、、~、^,,,、,~、
: 日 / 亻 + 彐 + 入 + 阝 / 刂
> ( 'c '(a b c d e f)) '(c d e f)
> ( 'c '((a b) (c d) (e f))) '(c d)
> (~ 'c '(a b c d e c f)) '(a b d e c f)
> (^ '(c e) '(a b c d e c f)) '(a b d f)
> ( 米? '(a b 1 c d 3 e 9 f)) 1
> ( 米? '(a b 1 c d 3 e 9 f)) '(1 3 9)
> ( 米? '(a b 1 c d 3 e 9 f)) '(1 c d 3 e 9 f)
> ( 米? '((a b) (1 d) (j k) (8 f))) '(1 d)
> ( 米? '(a b 1 c d 3 e 9 f)) '(a b c d e f)
> (~ 米? '(a b 1 c d 3 e 9 f)) '(a b c d 3 e 9 f)
5.1.17 分,巨
5.1.18 ,, ,,,右
Do not confuse with 攵. 入 component implies the input data is procedure.( PROC ( a b c)) is simplified from: ( (PROC a) (PROC b) (PROC c))( PROC ( a b c)) is simplf-from: (并 (PROC a) (PROC b) (PROC c))
( PROC ( a b c)) is simplified from: (戈 (PROC a) (PROC b) (PROC c))
( PROC z ( a b c)) is simplified from: (PROC c (PROC b (PROC a z)))
(右 PROC z ( a b c)) is simplified from: (PROC a (PROC b (PROC c z)))
> ( display ( 2 4 6 8)) 2468
> ( '(1 2 3 4)) '(2 3 4 5)
> ( + '(1 2 3 4) '(100 200 300 400)) '(101 202 303 404)
> ( ? '(1 2 -3 4)) #f
> ( + '(1 2 3 4) '(100 200 300 400)) 404
> ( ? '(1 2 -3 4)) #f
> ( + '(1 2 3 4) '(100 200 300 400)) 101
> ( + 0 '(1 2 -3 4)) 4
> ( 双 '() '(1 2 -3 4)) '(4 -3 2 1)
> (右 双 '() '(1 2 -3 4)) '(1 2 -3 4)
5.1.19 ,,、
> ( (入 (x) (并 (? x) ( x))) '(-2 -1 0 1 2)) '(2 3)
> ( 化 '(#(1) #(2 3) #(4))) '(1 2 3 4)
> ( char->integer '(#\a #\y #\b #\k #\c #\j #\d)) #\y
> ( char->integer '(#\a #\y #\b #\k #\c #\j #\d)) #\a
> ( 阳 '((3 pears) (1 banana) (2 apples))) '(3 pears)
> ( 阳 '((3 pears) (1 banana) (2 apples))) '(1 banana)
5.1.20 侕、,,
Since having 亻 and 而 , as a whole they specify the input is list and output is a list of lists.X stands for the methemathic sign of cartesian product(X). specifies the input to be more than one same type values.
> (侕 '(a b c)) '(() (a) (b) (a b) (c) (a c) (b c) (a b c))
> (侕 '(a b c) 2) '((a b) (a c) (b c))
> ( '(a b c)) '((a b c) (b a c) (a c b) (c a b) (b c a) (c b a))
> ( '(1 2 3) '(a b c) '(x y z))
'((1 a x)
(1 a y)
(1 a z)
(1 b x)
(1 b y)
(1 b z)
(1 c x)
(1 c y)
(1 c z)
(2 a x)
(2 a y)
(2 a z)
(2 b x)
(2 b y)
(2 b z)
(2 c x)
(2 c y)
(2 c z)
(3 a x)
(3 a y)
(3 a z)
(3 b x)
(3 b y)
(3 b z)
(3 c x)
(3 c y)
(3 c z))
> ( 米? '(1 a 2 b 3 c)) '((1 2 3) (a b c))
5.1.21 ming/racket/base
| (require ming/racket/base) | package: Ming |
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
: = build-list
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
5.1.22 ming/racket/list
| (require ming/racket/list) | package: Ming |
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
transformer
: 攸 + 入 = list-update
transformer
transformer
: = index-where
transformer
弓* : 弓 + *SFX = indexes-of
transformer
* : + *SFX = indexes-where
transformer
transformer
: + 阝 = take-right
transformer
transformer
: + = drop-right
transformer
transformer
: + 入 = takef-right
transformer
transformer
: + 入 = dropf-right
transformer
transformer
: + = split-at-right
transformer
transformer
: = splitf-at-right
transformer
? : + + ?SFX = list-prefix?
transformer
: + 同 + 阝 = take-common-prefix
transformer
: + 同 + = drop-common-prefix
transformer
: + 同 + = split-common-prefix
transformer
transformer
𰂋 : 𰂋 = add-between
transformer
transformer
transformer
重 : 重 = check-duplicates
transformer
𠝤 : 𠝤 = remove-duplicates
transformer
: = filter-not
transformer
transformer
transformer
: + = filter-map
transformer
: + = append-map
transformer
transformer
* : + *SFX = inclusive-range
transformer
侕 : 侕 = combinations
transformer
: = permutations
transformer
in侕 : i + n + 侕 = in-combinations
transformer
in : i + n + = in-permutations
transformer
transformer
transformer
transformer
: = cartesian-product
transformer