diff options
| author | Patrick Simianer <patrick@lilt.com> | 2026-02-26 10:05:59 +0000 |
|---|---|---|
| committer | Patrick Simianer <patrick@lilt.com> | 2026-02-26 10:05:59 +0000 |
| commit | b31ace79ea5f6b3f279c544cd3a443d6fbf2a24d (patch) | |
| tree | 31f2b599fa5f6996aeb134390d58deb63eefe04a /min-max | |
| parent | 8805e95ae94d798c6441f7e1b72c90e049563f17 (diff) | |
Diffstat (limited to 'min-max')
| -rwxr-xr-x | min-max | 17 |
1 files changed, 8 insertions, 9 deletions
@@ -1,15 +1,15 @@ -#!/usr/bin/ruby +#!/usr/bin/env ruby -require 'zipf' -require 'optimist' +require "zipf" +require "optimist" conf = Optimist::options do opt :min, "minimum #tokens", :type => :int, :default => 1 - opt :max, "maximum #tokens", :type => :int, :default => 80, :short => '-n' - opt :in_f, "input 'French' file", :type => :string, :required => true - opt :in_e, "input 'English' file", :type => :string, :required => true - opt :out_f, "output 'French' file", :type => :string, :required => true - opt :out_e, "output 'English' file", :type => :string, :required => true + opt :max, "maximum #tokens", :type => :int, :default => 80, :short => "-n" + opt :in_f, "input French file", :type => :string, :required => true + opt :in_e, "input English file", :type => :string, :required => true + opt :out_f, "output French file", :type => :string, :required => true + opt :out_e, "output English file", :type => :string, :required => true opt :out_id, "output line Nos", :type => :string, :required => true end @@ -37,4 +37,3 @@ while f_line = files[:f_file].gets end files.values.each{ |f| f.close } - |
