add generic fallback first() and last() that work for strings (among other things)