Skip to content

Instantly share code, notes, and snippets.

@j16r
Created February 24, 2022 12:42
Show Gist options
  • Save j16r/5d511e2b0b2ab66e71015b8a37f0d72d to your computer and use it in GitHub Desktop.
Save j16r/5d511e2b0b2ab66e71015b8a37f0d72d to your computer and use it in GitHub Desktop.
#!/usr/bin/env ruby
require 'date'
day = (Date.today - Date.civil(2021, 6, 19)).to_i
won = rand(5)+1
puts "Wordle #{day} #{won}/6"
tiles = ['🟩','🟨','⬛️']
(1..won-1).each do |row|
puts "#{5.times.collect { tiles.sample }.join}\n"
end
puts "#{tiles[0]*5}\n"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment