Rewrite check4progs from etc/grml/script-functions

This largely simplifies the function and also fixes its behaviour when
called with more than one argument.

Signed-off-by: Frank Terbeck <ft@grml.org>