Sha256: f2a5830c694fa3ac8656ccb0a928d72f08fe834172b4cffd4f8b473d477ea029

Contents?: true

Size: 398 Bytes

Versions: 79

Compression:

Stored size: 398 Bytes

Contents

#!/usr/bin/env ruby

# asking_for_arrays.rb
#
#  Created by James Edward Gray II on 2005-07-05.
#  Copyright 2005 Gray Productions. All rights reserved.

require "rubygems"
require "highline/import"
require "pp"

grades = ask( "Enter test scores (or a blank line to quit):",
              lambda { |ans| ans =~ /^-?\d+$/ ? Integer(ans) : ans} ) do |q|
  q.gather = ""
end

say("Grades:")
pp grades

Version data entries

79 entries across 69 versions & 11 rubygems

Version Path
challah-rolls-0.2.0 vendor/bundle/gems/challah-0.8.3/vendor/bundle/gems/highline-1.6.14/examples/asking_for_arrays.rb
challah-rolls-0.2.0 vendor/bundle/gems/highline-1.6.13/examples/asking_for_arrays.rb
challah-rolls-0.2.0 vendor/bundle/gems/highline-1.6.14/examples/asking_for_arrays.rb
challah-rolls-0.2.0 vendor/bundle/gems/highline-1.6.15/examples/asking_for_arrays.rb
challah-0.8.3 vendor/bundle/gems/highline-1.6.14/examples/asking_for_arrays.rb
challah-0.8.3 vendor/bundle/gems/highline-1.6.15/examples/asking_for_arrays.rb
challah-0.8.1 vendor/bundle/gems/highline-1.6.14/examples/asking_for_arrays.rb
highline-1.6.15 examples/asking_for_arrays.rb
challah-rolls-0.1.0 vendor/bundle/gems/highline-1.6.14/examples/asking_for_arrays.rb
challah-rolls-0.1.0 vendor/bundle/gems/challah-0.8.0.pre/vendor/bundle/gems/highline-1.6.13/examples/asking_for_arrays.rb
challah-rolls-0.1.0 vendor/bundle/gems/highline-1.6.13/examples/asking_for_arrays.rb
challah-0.8.0.pre vendor/bundle/gems/highline-1.6.13/examples/asking_for_arrays.rb
challah-0.7.1 vendor/bundle/gems/highline-1.6.13/examples/asking_for_arrays.rb
highline-1.6.14 examples/asking_for_arrays.rb
challah-0.7.0 vendor/bundle/gems/highline-1.6.13/examples/asking_for_arrays.rb
challah-0.7.0.pre2 vendor/bundle/gems/highline-1.6.13/examples/asking_for_arrays.rb
challah-0.7.0.pre vendor/bundle/gems/highline-1.6.13/examples/asking_for_arrays.rb
challah-0.6.2 vendor/bundle/gems/highline-1.6.13/examples/asking_for_arrays.rb
highline-1.6.13 examples/asking_for_arrays.rb