Skip to content

Instantly share code, notes, and snippets.


Create Root CA (Done once)

Create Root Key

Attention: this is the key used to sign the certificate requests, anyone holding this can sign certificates on your behalf. So keep it in a safe place!

openssl ecparam -genkey -name prime256v1 -noout -out rootCA.key
helios2k6 / stock_trading_calendar.json
Created Nov 5, 2021
United States Stock Market Ope and Close Hours from 2000-01-03 until 2029-12-24
View stock_trading_calendar.json
This file has been truncated, but you can view the full file.
"date": "2000-01-03",
"open": "09:30",
"close": "16:00",
"session_open": "0700",
"session_close": "1900"
helios2k6 / AnagramSingleWord.cs
Created Jun 10, 2019
Finding Substring Anagrams
View AnagramSingleWord.cs
using System;
using System.Collections.Generic;
using System.Linq;
public static class AnagramInSingleWord
private static void AddToSubstringDictionary(
string s, Tuple<int, int> startAndLength,
IDictionary<Tuple<int, int>, string> substrings
helios2k6 / DFT.cs
Last active Nov 14, 2016
DFT Implementations, including FFT
View DFT.cs
private static Complex[] DFTDirectComputation(Complex[] input)
int N = input.Length;
Complex[] output = new Complex[input.Length];
for (int k = 0; k < input.Length; k++)
var sum = new Complex();
for (int n = 0; n < input.Length; n++)
sum += input[n] * WFunction(N, k * n);
View Sequence Overflow.fs
let appendItem item sequence = seq { yield! sequence; yield item }
let testOverflow() =
seq { for i in 1..5000 do yield i }
|> Seq.fold (fun state item -> appendItem item state) Seq.empty
|> Seq.iter ignore