I offer this in the spirit of the old "purity test" and the
"nerdity test" that was derived therefrom.

Don't take it *too* seriously. All point weights are strictly
my opinion and are subject to change.


Version 1.0 follows... cut, paste, run. Or just cut and run.


Cheers,
Hal



def add(n)
   @sum += n
   puts "#{n} points  (#{@sum} total)"
   puts
end

def yorn
   print "(y/n): "
   ch = gets.chomp
   ch=='y' ? 1 : 0
end

@sum = 0

puts
puts "First, three background geek questions:"
puts

puts "How many degrees in computer science do you have?"
deg = gets.to_i
add(deg*4)

puts "In what year did your write your FIRST program in any language?"
fp = gets.to_i
div4 = ((Time.now.year - fp)/4.0).ceil
add(div4*1)

puts "How many years have you worked in a software-related job?"
yrs = gets.to_i
div4 = (yrs/4.0).ceil
add(div4*1)

puts "\n----------------------"
puts "And now the Ruby stuff:"
puts

puts "In what year did you start using Ruby? (4 digits)"
yr = gets.to_i
partial = Time.now.year - yr
add(partial*2)

puts "In what year did you start reading the list or newsgroup? (4 digits)"
yr = gets.to_i
partial = Time.now.year - yr
add(partial*4)

puts "How many (non-vaporware) entries do you have in RAA and/or Rubyforge?"
raa = gets.to_i
add(raa*1)

puts "How many Ruby conferences have you assisted in organizing? (US or other)"
conf = gets.to_i
add(conf*6)

puts "Have you assisted in forming a local user's group?"
local = yorn
add(local*2)

puts "At how many Ruby conferences have you made presentations?"
conf = gets.to_i
add(conf*6)

puts "How many Ruby conferences have you attended?"
conf = gets.to_i
add(conf*4)

puts "Now, some book questions."
puts "Translations and newer editions count separately..."
puts

puts "How many Ruby books list you as an author?"
book = gets.to_i
add(book*6)

puts "How many (other) Ruby books have you contributed to?"
book = gets.to_i
add(book*4)

puts "How many (other) Ruby books mention your name?"
book = gets.to_i
add(book*2)

puts "How many unique Ruby books do you own?"
books = gets.to_i
add(books*1)

puts "Do you own a domain name (with content) including the word 'ruby'?"
dom = yorn
add(dom*2)

puts "Approximately how many packages of yours are now in the core or stdlib?"
core = gets.to_i
add(core*1)

puts "Is your name Yukihiro Matsumoto?"
matz = yorn
add(matz*10)

puts "Is your name Dave Thomas or Guy Decoux?"
dave = yorn
add(dave*6)

puts "Is your name: Nobu Nokada, Shugo Maeda, or Minero Aoki?"
nobu = yorn
add(nobu*4)

puts "Do you know any Japanese?"
japan = yorn
add(japan*2)

puts "Is Japanese your first language?"
japan = yorn
add(japan*3)

puts "Have you ever written Ruby for pay?"
pay = yorn
add(pay*10)

puts "Estimate your total lines of Ruby code written."
loc = (gets.to_i/5000.0).ceil
add(loc*1)

puts "How many Ruby presentations have you made (outside RubyConf)?"
nconf = gets.to_i
add(nconf*4)

puts "How many of your Ruby packages have been downloaded >500 times?"
over500 = gets.to_i
add(over500*3)

puts "Ever had an RCR accepted?"
rcr = yorn
add(rcr*5)


puts "That's all... your Ruby Geek status is measured at #@sum."
puts "Have a great day, and keep coding!"
puts