Return to Snippet

Revision: 27491
at June 11, 2010 06:15 by heinz1959

Initial Code
#!/usr/bin/perl -wl


for $i (0 .. $#f) {
	$r=int rand ($i+1);
	@f[$i, $r][email protected][$r,$i] if ($i!=$r);

chomp @f;

print join $/, @f;

Initial URL

Initial Description
Need to "unsort" / randomize / scramble LINES in a text? Copy source -> then BBEdit -> File -> New -> Text Document -> paste source -> save as "Unsort" to ~/Library/Application Support/BBEdit/Unix Support/Unix Filters/  --- done

Initial Title
Unsort Lines BBEdit Unix Filter

Initial Tags

Initial Language