Task

Write a function to detect a   divide by zero error   without checking if the denominator is zero.




f(a, b) := block([q: errcatch(a / b)], if emptyp(q) then 'error else q[1]);
 
f(5, 6);
5 / 6
 
f(5, 0;)
'error