Made conditionals exercises more novice friendly.

This commit is contained in:
Brian Dawn 2015-06-14 11:09:15 -05:00
parent 3ddfe960b0
commit 29aedc3a6a

View File

@ -1,14 +1,12 @@
(ns koans.07-conditionals (ns koans.07-conditionals
(:require [koan-engine.core :refer :all])) (:require [koan-engine.core :refer :all]))
(defn explain-defcon-level [exercise-term] (defn explain-exercise-velocity [exercise-term]
(case exercise-term (case exercise-term
:fade-out :you-and-what-army :bicycling "pretty fast"
:double-take :call-me-when-its-important :jogging "not super fast"
:round-house :o-rly :walking "not fast at all"
:fast-pace :thats-pretty-bad "is that even exercise?"))
:cocked-pistol :sirens
:say-what?))
(meditations (meditations
"You will face many decisions" "You will face many decisions"
@ -40,10 +38,10 @@
'doom 'doom
'more-doom)) 'more-doom))
"In case of emergency, sound the alarms" "In case of emergency, go fast"
(= :sirens (= "pretty fast"
(explain-defcon-level __)) (explain-exercise-velocity __))
"But admit it when you don't know what to do" "But admit it when you don't know what to do"
(= __ (= __
(explain-defcon-level :yo-mama))) (explain-exercise-velocity :watching-tv)))