[2018][ruby][13.2] move the end condition to the right place

sorbet
Alpha Chen 6 years ago
parent c470c4ed9d
commit caa0ec1553

@ -107,16 +107,17 @@ loop do
# p y # p y
# carts.delete_if {|cart| cart.x == x && cart.y == y } # carts.delete_if {|cart| cart.x == x && cart.y == y }
# end # end
if carts.size == 1
p carts
exit
end
# if crashes.values.any? {|v| v > 1 } # if crashes.values.any? {|v| v > 1 }
# p crashes.find {|_,v| v > 1 } # p crashes.find {|_,v| v > 1 }
# exit # exit
# end # end
end end
if carts.size == 1
p carts
exit
end
# p carts # p carts
# sleep 1 # sleep 1
end end

Loading…
Cancel
Save