Substring/Top and tail: Difference between revisions

Added zsh solution
m (omissions)
(Added zsh solution)
Line 776:
upraiser
</pre>
 
=={{header|UNIX Shell}}==
Only zsh supports nest string manipulation.
 
<lang bash>
#!/bin/zsh
str='abcdefg'
echo ${str#?} # Remove first char
echo ${str%?} # Remove last char
echo ${${str#?}%?} # Remove first & last chars
</lang
 
=={{header|Vala}}==