When making this website, i wanted a simple, reasonable way to make it look good on most displays. Not counting any minimization techniques, the following 58 bytes worked well for me:
main {
max-width: 38rem;
padding: 2rem;
margin: auto;
}
This is free and unencumbered software released into the public domain. | |
Anyone is free to copy, modify, publish, use, compile, sell, or | |
distribute this software, either in source code form or as a compiled | |
binary, for any purpose, commercial or non-commercial, and by any | |
means. | |
In jurisdictions that recognize copyright laws, the author or authors | |
of this software dedicate any and all copyright interest in the | |
software to the public domain. We make this dedication for the benefit |
javascript:(d=>{var css=`:root{background-color:#fefefe;filter:invert(100%)}*{background-color:inherit}img:not([src*=".svg"]),video{filter: invert(100%)}`,style,id="dark-theme-snippet",ee=d.getElementById(id);if(null!=ee)ee.parentNode.removeChild(ee);else {style = d.createElement('style');style.type="text/css";style.id=id;if(style.styleSheet)style.styleSheet.cssText=css;else style.appendChild(d.createTextNode(css));(d.head||d.querySelector('head')).appendChild(style)}})(document) |
#include <time.h> // Robert Nystrom | |
#include <stdio.h> // @munificentbob | |
#include <stdlib.h> // for Ginny | |
#define r return // 2008-2019 | |
#define l(a, b, c, d) for (i y=a;y\ | |
<b; y++) for (int x = c; x < d; x++) | |
typedef int i;const i H=40;const i W | |
=80;i m[40][80];i g(i x){r rand()%x; | |
}void cave(i s){i w=g(10)+5;i h=g(6) | |
+3;i t=g(W-w-2)+1;i u=g(H-h-2)+1;l(u |
This bookmarklet expands the search bar when it is focused, similar to the wiki. | |
This is inspired by a suggestion I saw. | |
Versions | |
v1: Initial release | |
v2: Updated to use functions in the scratch-www events to prevent copy-pasting code | |
v2.1: Fixed a bug that prevented the search bar from unexpanding | |
v3: Tweaked to allow dynamic enabling and disabling (not in the bookmarklet though) | |
v4: Updated to catch up with the SA PR (obiviously with the addon APIs removed) |
module Lang exposing (..) | |
import Dict exposing (Dict) | |
import Type exposing (..) | |
type Lit | |
= IntLit Int | |
| CharLit Char |
If you are using this already, consider changes soon due the discussion around current ESX proposal.
Feel free to keep an eye on udomsay as that will be the implementation reference for consumers.
class RecursiveDescentParser<T extends { type?: string }> { | |
private readonly tokens: T[]; | |
private current = 0; | |
constructor(tokens: T[]) { | |
this.tokens = tokens; | |
} | |
/** | |
* Check if the current token matches one of the given types |
import writer | |
import string_writer | |
pub fn main() { | |
string_writer.create() | |
|> writer.write("Text1") | |
|> writer.write("Text2") | |
|> string_writer.print() | |
} |