title: How to create a hash of hashes in C++?
body: <p>Is there a way to create a hash of hashes in C++? </p>
  
  <p>Effectively I am trying to do what you can do in Perl but only in C++.
  Here is an example of Perl code I would like to have happen in C++</p>
  
  <pre><code>%hash = (
  gameobject1 =&gt; {
      position =&gt; {
          x_loc =&gt; 43,
          y_loc =&gt; 59,
      }
      rect_size =&gt; {
          width =&gt; 5,
          height =&gt; 3,
      }
      collidable =&gt; 1,
      sounds =&gt; {
          attack =&gt; "player_attack.ogg",
          jump =&gt; "player_jump1.ogg",
          jump_random =&gt; [qw/player_jump1.ogg player_jump2.ogg player_jump3.ogg/]
      }
  
  },
  gameobject2 =&gt; {
      position =&gt; {
          x_loc =&gt; 24,
          y_loc =&gt; 72,
      }
      rect_size =&gt; {
          width =&gt; 2,
          height =&gt; 4,
      }
      sounds =&gt; {
          attack =&gt; "goblin_attack.ogg",
      }
          items =&gt; [qw/sword helmet boots/]
  },
  );
  </code></pre>
  
  <p>The thing to note is the hashes with in gameobjects can exist or not... i.e. position might exist in gameobject1 but may not exist for gameobject35.</p>
  
  <p>Any ideas?</p>