gist: 1403 Download_button fork
public
Public Clone URL: git://gist.github.com/1403.git
Ruby
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# 'aaa' and 'a' are Arrays of Hashes
 
aaa.each do |hash_one|
 
  if a.find { |key_two, hash_two| hash_one == hash_two } do
 
    value_to_use = hash_two
 
  else
 
    value_to_use = hash_one
 
  end
 
  # Now do what you want to do with that
 
end

Owner

aflatter

Revisions