标签:ar strong c on r as d rom oo
Replacing an element of a list with another:
% lreplace {a b c d e} 1 1 foo a foo c d e
Replacing two elements of a list with three:
% lreplace {a b c d e} 1 2 three more elements a three more elements d e
Deleting the last element from a list in a variable:
% set var {a b c d e} a b c d e % set var [lreplace $var end end] a b c d
标签:ar strong c on r as d rom oo
原文地址:http://www.cnblogs.com/greencolor/p/4005722.html