Skip to content

Instantly share code, notes, and snippets.

@uppfinnarjohnny
Created November 24, 2011 14:20
Show Gist options
  • Save uppfinnarjohnny/1391453 to your computer and use it in GitHub Desktop.
Save uppfinnarjohnny/1391453 to your computer and use it in GitHub Desktop.
Something about lists, references and stuff, in php & python
$some_array[$some_id]['key_one'] = $value_one;
$some_array[$some_id]['key_two'] = $value_two;
$some_array[$some_id]['key_three'] = $value_three;
$item = &$some_array[$some_id];
$item['key_one'] = $value_one;
$item['key_two'] = $value_two;
$item['key_three'] = $value_three;
some_list[some_id].update({
'key_one': value_one,
'key_two': value_two,
'key_three': value_three
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment