#!usr/bin/env ruby # -*- coding: utf-8 -*- pz = NinePuzzle.new while !pz.finished pz.display n = gets.to-i pz.move(n) end puts "おめでとう!"