- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Dear forum members
I am looking for a way to add "X" to all lists inside a list
This is the list
(("ISO_PIPESPEC" "n.v.t.1" "Prompt 1") ("ISO_MEDIUM" "n.v.t.2" "Prompt 2") ("ISO_DESIGN_PRESS" "n.v.t.3" "Prompt 3"))
And I want to get it like this
(("ISO_PIPESPEC" "n.v.t.1" "Prompt 1" "X") ("ISO_MEDIUM" "n.v.t.2" "Prompt 2" "X") ("ISO_DESIGN_PRESS" "n.v.t.3" "Prompt 3" "X"))
Below is what I tried and didn't work out
Trying it like this
(foreach x vier (setq a (append a (car vier) '("X")))) will make 1 long list and I need multiple lists inside a list
trying this
(foreach x (car vier) (setq a (append a vier '("")))) will make the list how I want it only it placed the "X" 1 time as last list
Trying this
(foreach x vier (setq a (append a x '("")))) will make 1 long list and I need multiple lists inside a list
Trying this will add the value to each member of the lists
(mapcar '(lambda ( x ) (strcat "insert text here" x)) 'vier)
vier is the var name I used that contains the list
Kind Regards
Solved! Go to Solution.