Create a function total_seconds in libs/console to close #8.