Re: select N random lines in a file
On Sun, 2004-08-22 at 20:35, Lance Hoffmeyer wrote:
> Hello all,
>
> I would like to write a script that will select N number of
> random lines in a file. Any suggestions on how to do this?
>
Use the rand() function in awk
--
Oliver Elphick olly@lfix.co.uk
Isle of Wight http://www.lfix.co.uk/oliver
GPG: 1024D/A54310EA 92C8 39E7 280E 3631 3F0E 1EC0 5664 7A2F A543 10EA
========================================
"For yourselves know perfectly that the day of the Lord
so cometh as a thief in the night. For when they shall
say, Peace and safety; then sudden destruction cometh
upon them, as travail upon a woman with child; and
they shall not escape." I Thessalonians 5:2,3
Reply to: