Skip to content

Instantly share code, notes, and snippets.

@Ch3shireDev
Ch3shireDev / grammar.ebnf
Created December 1, 2019 19:45
grammar.ebnf
@@grammar::Something
start = expression $ ;
expression = term [or ~ expression];
term = factor [and ~ term];
factor
=
@Ch3shireDev
Ch3shireDev / list_class_structure.cs
Created November 19, 2019 08:57
Reflections - class structure
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Xml;
using FrPluginImporter.SadUe;
using SAD;
namespace XMLStructure
{
@Ch3shireDev
Ch3shireDev / main.cs
Created November 8, 2019 23:23
WPF C# - Wait for finish
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using System.Windows;
namespace BrokenLoader
{
/// <summary>
/// Interaction logic for MainWindow.xaml
/// </summary>
@Ch3shireDev
Ch3shireDev / primes.fs
Last active September 18, 2019 21:57
My first F# program - Primes
let prime n =
if n = 2 then true
else
let arr = [for i in 2..n-1 -> n%i=0]
List.contains true arr |> not
//let choiser elem = if elem > 0 then Some(elem) else None
//let f x = List.choose choiser x
let primes = List.choose (fun i -> if (prime i) then Some(i) else None) [2..500]
@Ch3shireDev
Ch3shireDev / httpd.asm
Created October 23, 2017 18:53 — forked from xenomuta/httpd.asm
httpd.asm: Arguably the world smallest web server. ( for GNU/Linux i386. Compile with nasm )
section .text
global _start
_start:
xor eax, eax
xor ebx, ebx
xor esi, esi
jmp _socket
_socket_call: