This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import XCPlayground | |
import Foundation | |
// in Xcode 7 use Editor/Show Rendered Markup to display the formatted comments | |
//: # First things first: The Protocols | |
//: It is good Swift practice to start with your protocols | |
//: Instead of a common base classes we define protocols | |
protocol Hardware { | |
var name: String {get} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; Slightly enhanced version of Alex Osborne's debug-repl (http://gist.github.com/252421) | |
;; Typing () quits the debug REPL, making it possible to continue without terminating the | |
;; input stream by typing Ctrl-D. | |
;; Inspired by George Jahad's version: http://georgejahad.com/clojure/debug-repl.html | |
;; (.setDynamic #'*locals*) added | |
(ns debug | |
[:require clojure.main]) |