Skip to content

Instantly share code, notes, and snippets.

using System;
using System.IO;
using System.Net;
using System.Runtime.Serialization.Json;
using System.Text;
/// <summary>
/// Strongly typed GET and POST utility enum.
/// </summary>
public enum HTTPMethod
@SoundLogic
SoundLogic / roslyn2jsSequenceDiagrams.cs
Last active September 21, 2022 14:33
P.O.C. for UML sequence diagram project leveraging Roslyn
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.CSharp;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using Microsoft.CodeAnalysis.MSBuild;
using Microsoft.CodeAnalysis.FindSymbols;
@SoundLogic
SoundLogic / roulette.cs
Last active August 29, 2015 14:02
why casinos have maximum (and strategically relative minimum) bets (you would need a pretty hefty bankroll for this even if you start with a $5 base bet)
using System;
namespace Roulette
{
class Program
{
static void Main(string[] args)
{
var r = new Random();
double highestCumulativeLossPointOfAnySimulation = 0;
@SoundLogic
SoundLogic / 0_reuse_code.js
Last active August 29, 2015 14:06
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@SoundLogic
SoundLogic / knights-tour.html
Created November 28, 2014 21:26
javascript based solution for the Knight's Tour puzzle (http://en.wikipedia.org/wiki/Knight%27s_tour)
<html>
<head>
<style>
a {
color:#000;
display:block;
font-size:60px;
height:80px;
position:relative;
text-decoration:none;