How to assign a div class to a echo function [closed]

This is not a specific WordPress question, is a topic in php coding.

You can add html markup inside the echo in your function, like the follow example:

function show_today_date() {

    echo '<div class="example">' . date( get_option( 'date_format' ) ) . '</div>';
}
add_shortcode( 'showtodaydate', 'show_today_date' );