How can i retrieve a list of items (string) which contain a specific word from another list. Here is an Example :
(setq l '("word1_jj" "word2_mm" "word3_jj" "word4_kk"))
I wanna extract all string in which figure "_jj.
How can i retrieve a list of items (string) which contain a specific word from another list. Here is an Example :
(setq l '("word1_jj" "word2_mm" "word3_jj" "word4_kk"))
I wanna extract all string in which figure "_jj.
Copyright © 2021 Jogjafile Inc.
You should make
ends-with-pthat takes the word and an ending. To do that you find out how many characters there is in the two strings and usesubseqto make a string consisting of the last letters of the word. You can useequalto check it with the supplied argument it should match.When you have that you can do this:
Alternatively you could make a
make-end-predicatethat returns alambdathat takes a word: