From: "Esteban Manchado Velázquez" Date: 2006-05-15T19:53:32+09:00 Subject: Re: begining programmer questions --ZfOjI3PrQbgiZnxM Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi, On Mon, May 15, 2006 at 08:46:58AM +0900, Michael Gorsuch wrote: > Here is the code I am going by: >=20 > def input > puts "Enter some info" > info =3D [] > info << gets.chomp > while info.last !=3D "exit" > info << gets.chomp > end > info.sort > puts info > end Hmmm... note that the "sort" method _doesn't_ change the object. You should put either (1) info.sort! instead of info.sort, or (2) replace both lines with "puts info.sort". --=20 Esteban Manchado Vel=E1zquez - http://www.foton.es EuropeSwPatentFree - http://EuropeSwPatentFree.hispalinux.es --ZfOjI3PrQbgiZnxM Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.3 (GNU/Linux) iD8DBQFEaF2jhYgK5b1UDsERAi6JAJ4oKaXbSGO3apDf1U8aZ85YTF2yTwCfZzZC 3zQp1QFPX9P7YzzUxjkRMI0= =2PY3 -----END PGP SIGNATURE----- --ZfOjI3PrQbgiZnxM--