This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import collections | |
import pprint | |
dict_factory = lambda: collections.defaultdict(dict_factory) | |
x = collections.defaultdict(dict_factory) | |
x['a']['b']['c']['d'] = 1 | |
print x['a']['b']['c']['d'] | |
print pprint.pformat(x) # looks a bit messy, but it gives you the idea |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
x = {} | |
x['a']['b']['c']['d'] = 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use strict; | |
use Data::Dumper; | |
my $x; | |
$x->{a}->{b}->{c}->{d} = 1; | |
print Dumper($x) | |
=begin output |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script type="text/javascript"> | |
$(function() { | |
var widths = new Array; | |
/* get max column widths from tables */ | |
$('table').each(function() { | |
i = 0; | |
$(this).find('thead th').each(function() { | |
w = $(this).width(); |
NewerOlder