#!/usr/koeki/bin/ruby # -*- coding: utf-8 -*- IO.foreach("roll.txt") do |msg| msg.chomp! length=msg.length 0.upto(length-1) do |i| STDERR.print "\r" + " "*(length-1-i) + msg[0..i] + " " sleep(0.05) end print "\n" end