Number of rows that would have been returned in case of Limit in mysql

The thing is, you would have sql that have LIMIT appended at the end like

select * from sometable limit 25

but what if you wanted to know how many rows would have been returned if it was not limited?
the trivial approach is

select count(*) from sometable

and then issuing query with limit on it.
This is slower solution.
here is the way to do it in a better way

select sql_calc_found_rows * from sometable limit 25;
select found_rows();

Right after execution the select with sql_calc_found_rows, we would get the ‘would have been’ value on the second query.