Sha256: e78c52cd644118cbff7f9ad21bd663e8db81b7cb0beee3aedcb901bc60033d68

Contents?: true

Size: 338 Bytes

Versions: 34

Compression:

Stored size: 338 Bytes

Contents

class Object
  # a method that outputs several items on one line
  # similar to using pp, this space separates the items passed in and writes them to one line
  # sputs 1,2,3
  # => 1 2 3
  def pps *args
    for arg in args
      out = arg.to_s
      print out
      print " " if out[-1..-1] != " "
    end
    puts
  end
end

Version data entries

34 entries across 34 versions & 1 rubygems

Version Path
sane-0.25.8 lib/sane/pps.rb
sane-0.25.7 lib/sane/pps.rb
sane-0.25.6 lib/sane/pps.rb
sane-0.25.5 lib/sane/pps.rb
sane-0.25.4 lib/sane/pps.rb
sane-0.25.3 lib/sane/pps.rb
sane-0.25.2 lib/sane/pps.rb
sane-0.25.1 lib/sane/pps.rb
sane-0.25.0 lib/sane/pps.rb
sane-0.24.6 lib/sane/pps.rb
sane-0.24.5 lib/sane/pps.rb
sane-0.24.4 lib/sane/pps.rb
sane-0.24.3 lib/sane/pps.rb
sane-0.23.6 lib/sane/pps.rb
sane-0.24.2 lib/sane/pps.rb
sane-0.24.1 lib/sane/pps.rb
sane-0.24.0 lib/sane/pps.rb
sane-0.23.5 lib/sane/pps.rb
sane-0.23.4 lib/sane/pps.rb
sane-0.23.3 lib/sane/pps.rb