hybridgroup/kidsruby — Issue #29: Output viewer doesn't honor whitespace
Author: dougbradbury
Created: 2011-11-08 12:39:57+00:00
State: open

One of the lesson's in Chris Pine's tutorial teaches the string methods center, ljust, and rjust.
Whitespace get collapsed though in output viewer so the student can't tell if their code is working.

line_width = 50
puts( 'Sat in her cupboard'.center(line_width))
Pine. Learn to Program, 2e (Doug Bradbury) (Kindle Locations 637-638). The Pragmatic Bookshelf (309187).