How to Convert Date to Time ago WordPress

How to Convert a date to time ago

This Snippet is supposed to add in single.php, index.php or any other template within the loop. Don’t you think it would be finest thing to display on post where you can show post like “1 hour ago, 2 hour ago, 1 day ago” etc.

echo human_time_diff( get_the_time('U'), current_time('timestamp') ) . ' ago';

via Codex , Thumbnail image via inspirationde