use HTML::HTML5::Builder qw[:standard]; my @things = ( "raindrops on roses", "whiskers on kittens", "bright copper kettles", "warm woollen mittens", ); print html( -lang => 'en', head( title('Test'), Meta(-charset => 'utf-8'), ), body( h1('Test'), p('Here are a few of my favourite things...'), ul(map li($_), @things), ), );