summaryrefslogtreecommitdiff
path: root/scripts/free917/sigf_format.rb
blob: beac2e7323fe05af664d5c9c55d24e50bdcffde7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/usr/bin/env ruby

require 'zipf'


gold = ReadFile.readlines_strip ARGV[0]
i = -1
while line = STDIN.gets
  i += 1
  line.strip!
  a = [0, 0, 1]
  if line==gold[i]
    a[0] = 1
    a[1] = 1
  elsif line!=''
    a[1] = 1
  end
  puts a.join " "
end