#!/usr/local/bin/perl -s if($F) {$sep = shift;} else {$sep = '\s+';} if($R) {$\ = shift;} if ($mail){ mail2sexp(); } elsif ($sc){ # spread sheet format sc2sexp(); } else{ txt2sexp(); } sub sc2sexp{ print"("; while(<>){ chop; print "("; for(split(/$sep/)){ print "\"$_\" " ;} print ")\n"; } print")"; } sub txt2sexp{ print"("; while(<>){s/[\\"]/\\$&/g; chop ; print"\"$_\"\n" ;} print")\n"; }