my @a = map { my %h; @h{qw( chapter name )} = split / \.+ /; \%h } split / (?=\d)/, $str;