use strict; use warnings; binmode STDOUT, ":utf8"; use utf8; use JSON; my $json; { local $/; open my $fh, "<", "struc_cover_edu.json"; $json = <$fh>; close $fh; } my $j = JSON->new->decode($json); for my $s (@$j) { next unless $s->{PROT_NAME} eq 'XPA'; for my $p (@{$s->{COVERTURA}}) { print $p->{PSTART},"\n"; } }