             [pronouns.util :as u]
             [hiccup.core :refer :all]
             [hiccup.util :refer [escape-html]]))
+
+(defn prose-comma-list
+  [items]
+  (let [c (count items)]
+    (cond
+      (<= c 1) (first items)
+      (= c 2) (s/join " and " items)
+      :else (str (s/join ", " (butlast items)) ", and " (last items)))))
 
 (defn href
   [url text]

                   (wrap-pronoun reflexive)
                   "."))

(defn title-block [title]
  [:div {:class "section title"}
   [:h1 title]])

(defn examples-block
  [subject object possessive-determiner possessive-pronoun reflexive]
  (let [sub-obj (str subject "/" object)
        header-str (str "Here are some usage examples for my "
                        sub-obj
                        " pronouns")]
    [:div {:class "section examples"}
     [:h2 header-str]
     [:p (subject-example subject)


(defn format-pronoun-examples
  [pronoun-declensions]
  (let [sub-objs (map #(s/join "/" (take 2 %)) pronoun-declensions)
        title (str "Pronoun Island: " (prose-comma-list sub-objs) " examples")]
    (html
     [:html
      [:head
