Trimming the spaces

Hi,
How can I remove the unwanted spaces in the line.
123456 789 ABC DEF. - I wanna remove the sapces in this line, I need the output 123456789ABCDEF.

Pls help me......

example:

echo "1 2 3 4 5" |tr -d [:SPACE:]

will do the trick

/peter

echo 123456 789 ABC DEF | sed "s/ //g"

This might help u!

$ str="123456 789 ABC DEF."
$ print ${str// /}
123456789ABCDEF.
$