input_file = ARGV[0] output_file = ARGV[1] f = open(input_file, "r") input = f.read f.close a = 2 b = input.to_i - a f_w = open(output_file, "w") f_w.puts(a.to_s + " " + b.to_s) f_w.close