};
$tree->find('tbody')->find('tr')->iter3($args{st}, $iter);
}
+
+sub process_ed {
+ my ($tree, %args) = @_;
+ my $iter = sub {
+ my ($data, $div) = @_;
+ $div->set_child_content(class => 'value', $data->{value});
+ $div->set_child_content(class => 'solution', literal $data->{solution});
+ $div->fclass('problem')->namedlink($data->{id}, $data->{name});
+ };
+ my @pb = map { @{$args{$_}} } qw/beginner easy medium hard/;
+ $tree->fclass('well')->iter3(\@pb, $iter);
+}
<div id="links">
<a href="/pb/?contest=contest_id">Problems</a><br>
+<a href="/ed/contest_id">Editorial</a><br>
<a href="/log/?contest=contest_id">Job log</a><br>
<a href="/st/contest_id">Standings</a>
</div>