   (let [before-last-switch (elements-before-last-switch args)
         last-switch-in-seq (when before-last-switch
                              (nthnext args before-last-switch))
-        possible-write-switch (when before-last-switch
-                                (first last-switch-in-seq))
-        write? (#{"-w" "--write" "-lw" "-cw" "-lcw" "-clw"
-                  "--list-changed-write" "--changed-list-write" "--list-write"
-                  "--changed-write"}
-                possible-write-switch)
-        changed? (when write?
-                   (clojure.string/includes? possible-write-switch "c"))
-        list? (when write? (clojure.string/includes? possible-write-switch "l"))
-        files (when write? (next last-switch-in-seq))
-        args (if write? (take before-last-switch args) args)
-        #_#_options?
-          (and (first args)
-               (clojure.string/starts-with? (clojure.string/trim (first args))
-                                            "{"))
-        #_#_write-switch (if options? (second args) (first args))
-        #_#_write? (or (= "-w" write-switch) (= "--write" write-switch))
-        #_#_files (when write? (if options? (nnext args) (next args)))
-        ; Now that we have the --write/-w stuff out of the way, process
-        ; switches and options, having first removed the --write/-w stuff,
-        ; if any
-        #_#_args (if write? (if options? (take 1 args) nil) args)
+        possible-wc-switch (when before-last-switch
+                             (clojure.string/trim (first last-switch-in-seq)))
+        write-set #{"-w" "-lw" "-lfw" "-lsw" "-lfsw" "-fw" "-fsw" "-sw" "-flw"
+                    "-flsw" "-fslw" "-sfw" "-slw" "-sflw" "-slfw" "--write"
+                    "--list-write" "--list-formatted-write"
+                    "--list-format-write" "--list-formatted-summary-write"
+                    "--formatted-write" "--list-format-summary-write"
+                    "--format-write" "--formatted-summary-write"
+                    "--summary-write" "--format-summary-write"}
+        check-set #{"-c" "-lc" "-lfc" "-lsc" "-lfsc" "-fc" "-fsc" "-sc" "-flc"
+                    "-flsc" "-fslc" "-sfc" "-slc" "-sflc" "-slfc" "--check"
+                    "--list-check" "--list-formatted-check"
+                    "--list-format-check" "--list-formatted-summary-check"
+                    "--formatted-check" "--list-format-summary-check"
+                    "--format-check" "--formatted-summary-check"
+                    "--format-summary-check" "--summary-check"}
+        write? (write-set possible-wc-switch)
+        check? (check-set possible-wc-switch)
+        [list? formatted? summary?]
+          (when (or write? check?)
+            (if (clojure.string/starts-with? possible-wc-switch "--")
+              [(clojure.string/includes? possible-wc-switch "list")
+               (or (clojure.string/includes? possible-wc-switch "formatted")
+                   (clojure.string/includes? possible-wc-switch "format"))
+               (clojure.string/includes? possible-wc-switch "summary")]
+              [(clojure.string/includes? possible-wc-switch "l")
+               (clojure.string/includes? possible-wc-switch "f")
+               (clojure.string/includes? possible-wc-switch "s")]))
+        files (when (or write? check?) (next last-switch-in-seq))
+	; Remove write or check switch and files, if any
+        args (if (or write? check?) (take before-last-switch args) args)
         options (first args)
         _ (prn "args:" args)
         _ (println)
         _ (prn "before-last-switch:" before-last-switch
-               "possible-write-switch:" possible-write-switch
+               "possible-wc-switch:" possible-wc-switch
                "write?" write?
+               "check?" check?
                "list?" list?
-               "changed?" changed?
+               "formatted?" formatted?
+               "summary?" summary?
                "files:" files)
         ; Some people wanted a zprint that didn't take configuration.
         ; If you say "--default" or "-d", that is what you get.

     ""
     "  -d  --default      Accept no configuration input."
     "  -u  --url URL      Load options from URL."
     "      --url-only URL Load only options found from URL, ignore all others."
     ""
     " <switches> which format named files:  May follow a configuration switch"
     "                                       or an options map, but not both"
     ""
     "  -w  --write FILE                read, format, and write to FILE (or FILEs),"
     "                                  -w *.clj is supported."
     "  -lw  --list-write FILE          like -w, but indicate which files processed."
     "  -cw  --changed-write FILE       like -w, but indicate which files changed."
     "  -lcw --list-changed-write FILE  like -w, but indicate files both processed"
     "                                  and changed."
     ""
     " The -w switch is the only switch where you may also have an options map!"
     ""]))


(defn write-to-stderr
  "Take a string, and write it to stderr."

             "count-before-last-switch" count-before-last-switch)
    count-before-last-switch))

(defn pair-sum
  "Sum two vector pairs."
  [[a b] [c d]]
  [(+ a c) (+ b d)])

;;
;; # Main
;;
