From: Harvie Date: Sun, 13 Jun 2010 22:30:27 +0000 (+0200) Subject: some PERL playing with JSON X-Git-Url: http://git.harvie.cz/?a=commitdiff_plain;h=0c2321c36d3bc4ec772822e256b35298b488f464;p=mirrors%2FPrograms.git some PERL playing with JSON --- diff --git a/perl/map-reduce/recursive-json.pl b/perl/map-reduce/recursive-json.pl new file mode 100755 index 0000000..8c57d00 --- /dev/null +++ b/perl/map-reduce/recursive-json.pl @@ -0,0 +1,12 @@ +#!/usr/bin/env perl +use strict; +use warnings; + +use JSON; +use Data::Dumper; + +my $a={a=>{f=>"",b=>""},b=>{f=>"",b=>""}}; +$a->{"b"}=$a; + +print Dumper($a); +print encode_json($a)."\n"