Added "type" pattern
Optimized "car", "cdr", "last" and "cadr"