pastebin

Paste Search Dynamic
Recent pastes
json data
  1. use strict;
  2. use warnings;
  3. use JSON;
  4.  
  5. my $json_data = '[{"name":"foo","id":"100"},{"name":"bar","id":"110"},{"name":"baz","id":"120"}]';
  6. my $items = JSON->new()->decode($json_data);
  7.  
  8. foreach my $item (@$items) {
  9.     printf "%s,%sn", $item->{name}, $item->{id};
Parsed in 0.006 seconds