BUTMEMBER (BM)

Syntax

BUTMEMBER word1 or list1 word2 or list2

BM word1 or list1 word2 or list2

Explanation

BUTMEMBER outputs a word or list consisting of its second input with all occurences of its first input removed. It the second input is a word, the first input must also be a word. If the second input is a list, the first input can be either a word or list.

See also BUTFIRST and BUTLAST.

Examples

? BUTMEMBER "AM [HI I AM FRED]

Result: [HI I FRED]

? BM "D "ABCDABCDABCD

Result: ABCABCABC

? BUTMEMBER 22 [11 22 33 44 55]

Result: [11 33 44 55]

? BUTMEMBER [JANUARY 1] JANUARY 1][JULY 4][DECEMBER 25

Result: JULY 4][DECEMBER 25

?