Take a look at the Installing Modules section from tutorials. Also Yes, even you can use CPAN, may be worth reading.
Update: the module name is Expect, remember to use the correct case:
>cpan ExpectMartin
In reply to Re: how to install expect on a remote machine!
by marto
in thread how to install expect on a remote machine!
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |