r3/gen_routes.rb

8 lines
247 B
Ruby
Raw Normal View History

#!/usr/bin/env ruby
arr = ["foo", "bar", "baz", "qux", "quux", "corge", "grault", "garply"]
paths = arr.permutation(3).map { |a| "/#{a.join '/'}" }
paths.each do |path|
2014-05-16 09:43:54 -04:00
# puts "r3_tree_insert_path(n, \"#{path}\", NULL);"
puts path
end