;;;; 5.lisp (defpackage #:aoc/2015/5 (:use #:cl)) (in-package #:aoc/2015/5) (defun vowel-p (ch) (declare (type character ch)) (or (eq ch #\a) (eq ch #\e) (eq ch #\i) (eq ch #\o) (eq ch #\u))) (defun three-vowels-p (str) (> (remove-if-not #'vowel-p str) 3)) (defun nicep (str) (declare (type string str)) (and (three-vowels-p str) (double-letter-p str) (not (bad-strings-p str))))