+ $tree->fid('track_user')->attr('data-user', $args{id});
+ my @solved = map { $_->{solved} ? ($_->{problem}) : () } @{$args{problems}};
+ my @attempted = map { !$_->{solved} ? ($_->{problem}) : () } @{$args{problems}};
+
+ my $pbiter = sub {
+ my ($data, $li) = @_;
+ $li->find('a')->namedlink($data);
+ };
+ $tree->fid('solved')->find('li')->iter3(\@solved, $pbiter);
+ $tree->fid('attempted')->find('li')->iter3(\@attempted, $pbiter);
+ $tree->fid('solved_count')->replace_content(scalar @solved);
+ $tree->fid('attempted_count')->replace_content(scalar @attempted);
+
+ my $ctiter = sub {
+ my ($data, $td) = @_;
+ $td->fclass('contest')->namedlink($data->{contest}, $data->{contest_name});
+ $td->fclass('score')->replace_content($data->{score});
+ $td->fclass('rank')->replace_content($data->{rank});
+ };
+ $tree->find('table')->find('tbody')->find('tr')->iter3($args{contests}, $ctiter);