+say '<tfoot>', $header;
+{
+ # prefix indicates browser family; count adjacent families
+ my (@families, %familycount);
+ for my $browser (@browsers) {
+ my $family = $caniuse->{agents}->{$browser}->{prefix};
+ push @families, $family unless $familycount{$family};
+ $familycount{$family} += @{ $versions{$browser} };
+ }
+
+ print "\n", '<tr class="cat">';
+ printf '<th colspan="%d">%s', $familycount{$_}, $_ for @families;
+}
+say '</tfoot>';