#lang racket (require net/zmq) (define ctxt (context 1)) (define sock (socket ctx `REQ)) (printf "Connecting to hello world server...\n") (socket-connect! sock "tcp://localhost:5555") (for ([request (in-range 10)]) (printf "Sending request ~a...\n" request) (socket-send! sock #"Hello") (define message (socket-recv! sock)) (printf "Received reply ~a [~a]\n" request message)) (context-close! ctxt)