1b60bee8a3
I'm in ur base polluting your language with all my opinions!
12 lines
267 B
Hy
12 lines
267 B
Hy
(import-from gevent.server StreamServer)
|
|
|
|
|
|
(defn handle [socket address]
|
|
(.send socket "Hello from Lisp!\n")
|
|
(for [x (range 5)] (.send socket (+ (str x) "\n")))
|
|
(.close socket))
|
|
|
|
|
|
(setv server (StreamServer (, "127.0.0.1" 5000) handle))
|
|
(.serve-forever server)
|