By Leo Rudberg ([email protected]). Written for the Spring 2018 CUNY Hackathon.
Link to this: https://bit.ly/2vTeHy1.
Follow me on GitHub!
(I will likely schmooze about myself here...)
| package test | |
| import ( | |
| "bytes" | |
| "encoding/json" | |
| "testing" | |
| "github.com/golang/protobuf/jsonpb" | |
| structpb "github.com/golang/protobuf/ptypes/struct" | |
| "github.com/google/cel-go/cel" |
| package main | |
| import ( | |
| "flag" | |
| "fmt" | |
| "image" | |
| "image/color" | |
| "image/png" | |
| "log" | |
| "math/rand" |
| package main | |
| // Usage: | |
| // ./petanque -img=/path/to/input.png -colors="ABCDEF,123456,00F001" | |
| import ( | |
| "flag" | |
| "fmt" | |
| "image" | |
| "image/color" |
By Leo Rudberg ([email protected]). Written for the Spring 2018 CUNY Hackathon.
Link to this: https://bit.ly/2vTeHy1.
Follow me on GitHub!
(I will likely schmooze about myself here...)
| // | |
| // main.cpp | |
| // test!!! | |
| // | |
| // Created by Leo Rudberg on 3/1/13. | |
| // Copyright (c) 2013 Leo Rudberg. All rights reserved. | |
| // | |
| #include <iostream> | |
| #include <string> |
In this Gist, I'll show you how to get a simple HTTP/JSON server working with the Go programming language.
Link to this guide: goo.gl/cDvRKj.
Thanks to Evan for critiquing this guide!
Go is an open source programming language made by Google and used by many developers around the world.
Link to this page: https://goo.gl/p5sZJz
Aloha CUNY Hackathon 2017!!! This has been updated for the November 2017 CUNY Hackathon.
tl;dr
| -- Based off of the Peter Norvig Python implementation: | |
| -- http://norvig.com/spell-correct.html | |
| module Spell where | |
| import qualified Data.Map.Strict as Map | |
| import qualified Data.List as List | |
| import qualified Data.Set as Set | |
| wordProbability :: Fractional v => Map.Map String v -> String -> v | |
| wordProbability allWords myWord = |
| #include <stdlib.h> | |
| #include <stdio.h> | |
| extern char * GoStrEq(char * cs1, char * st2); | |
| int main(int argc, char ** argv) { | |
| char * s1; | |
| char * s2; | |
| if (argc == 3) { |
| #!/usr/bin/env ruby | |
| # be sure to run `gem install octokit` | |
| require 'octokit' | |
| # `io/console` does not need to be installed, just required | |
| require 'io/console' | |
| def get_input(message, hide_entry = false) | |
| print message + '? ' | |
| if hide_entry |