Sha256: ab93e3befa9fea54733313d1f9c924d46fa99899c0bead1df28a07c8b4b02ff1
Contents?: true
Size: 1.02 KB
Versions: 13
Compression:
Stored size: 1.02 KB
Contents
gcd.rb:4 def gcd(a, b) # # *************************************************** # # This tests step, next, finish and continue # # *************************************************** # set debuggertesting on Currently testing the debugger is on. # set callstyle last Frame call-display style is last. # next gcd.rb:18 gcd(3,5) # where --> #0 at line gcd.rb:18 # step a Step argument 'a' needs to be a number. # set forcestep on force-stepping is on. # step- ; step- gcd.rb:6 if a > b # set forcestep off force-stepping is off. # where --> #0 Object.gcd(a#Fixnum, b#Fixnum) at line gcd.rb:6 #1 at line gcd.rb:18 # n 2 gcd.rb:10 return nil if a <= 0 # step+ gcd.rb:12 if a == 1 or b-a == 0 # where --> #0 Object.gcd(a#Fixnum, b#Fixnum) at line gcd.rb:12 #1 at line gcd.rb:18 # step 3 gcd.rb:6 if a > b # step+ gcd.rb:10 return nil if a <= 0 # where --> #0 Object.gcd(a#Fixnum, b#Fixnum) at line gcd.rb:10 #1 Object.-(a#Fixnum, b#Fixnum) at line gcd.rb:15 #2 at line gcd.rb:18 # next+ gcd.rb:12 if a == 1 or b-a == 0 # # finish # quit
Version data entries
13 entries across 13 versions & 4 rubygems