Afficher un message
Vieux 22/08/2006, 08h06   #3
Hubble
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: first letter of the word in CAPS


aarcee schrieb:

> Hello all ,
>
> I need to display a word with the first character in CAPS .
>
> that is , split then the display should be Split
>
> Thanks
> RC


#!/bin/sh
PATH=/bin:/usr/bin

for arg
do
firstchar=`echo "$arg" | cut -c1`
# assume echo -n does not print newline
echo -n $firstchar | tr a-z A-Z
echo "$arg" | sed -s s/^.//
done


Hubble

  Réponse avec citation
 
Page generated in 0,05107 seconds with 9 queries