# A very basic HTTP server
require "http/server"
server = HTTP::Server.new do |context|
context.response.content_type = "text/plain"
context.response.print "Hello world, got #{context.request.path}!"
end
puts "Listening on http://127.0.0.1:8080"
server.listen(8080)
Nicely concise!This would be the Python equivalent:
# A very basic HTTP server
from http.server import BaseHTTPRequestHandler, HTTPServer
class RequestHandler(BaseHTTPRequestHandler):
def do_GET(self):
self.send_response(200)
self.send_header('Content-type', 'text/plain')
self.end_headers()
self.wfile.write(bytes(f"Hello world, got {self.path}!", 'utf8'))
httpd = HTTPServer(('', 8080), RequestHandler)
print("Listening on http://127.0.0.1:8080")
httpd.serve_forever()
Would like to see it in more languages.I’ve tried OpenOffice and I became frustrated.
I personally find it a bit easier to use with better docx support.
It sounds very fair to me, what are the general thoughts here?
Should Unity still be entitled to the same cut?
The vast majority of people who are visiting subreddits are doing so because they're actively seeking out the material being presented to them. These people are subscribers to the subreddits. Subreddits that "go dark" are not blocked for everyone. Their access is restricted ONLY for those who have not yet subscribed to the subreddit.
So this giant display of enlightened asshattery affects almost nobody. And even if it did, it's a 2 day ordeal.
Which means jack fucking squat. It's the equivalent of wearing an MLK bandana on Juneteenth day and spending the rest of the year voting and campaigning for politicians trying to abolish what's left of the Voting Rights Act.
Private subreddits are indeed invitation only
But in the last 6 months or so, Google's results have gotten so bad and DDG has continued to improve to the point where I no longer bother with !g.
When I do use Google I often find myself in the strange position of not actually being able to find what I'm looking for. It's a very unsettling feeling, and not one I've experienced in a long time, possibly not since the pre-Google days of Yahoo, Lycos and AltaVista. Amazing that Google have let their core value proposition of 'we are much better at finding what you're looking for than everyone else' rot quite so much.