📄 07 - iterating over a hash in insertion order.rb
字号:
require 'orderedhash'h = OrderedHash.newh[1] = 1h["second"] = 2h[:third] = 3h.keys # => [1, "second", :third]h.values # => [1, 2, 3]h.each { |k,v| puts "The #{k} counting number is #{v}" }# The 1 counting number is 1# The second counting number is 2# The third counting number is 3#---
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -