This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
open import Agda.Builtin.Equality | |
record _∧_ (A B : Set) : Set where | |
constructor conj | |
field | |
proj₁ : A | |
proj₂ : B | |
data List (A : Set) : Set where |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Note: The same warnings about ListT's poor behavior apply to this transformer. | |
-- https://wiki.haskell.org/ListT_done_right | |
import Data.List.NonEmpty | |
import Control.Monad | |
import Control.Monad.List | |
newtype NonEmptyT m a = NonEmptyT { unNonEmptyT :: m (NonEmpty a) } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.ArrayList; | |
import java.util.Collection; | |
public class CollRaw { | |
public static interface Test { | |
public StringBuilder append(Collection<?> value); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; manual | |
10000 times { | |
a := 1. | |
a= := { parent a := #'($1). }. | |
do { a = 2. }. | |
}. | |
;; assignable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Haskell program which generates the table | |
import Data.Ratio | |
import Data.List | |
divides :: Integral a => a -> a -> Bool | |
divides y x = x `mod` y == 0 | |
primeFactors :: Integral a => a -> [a] | |
primeFactors n | n < 1 = error "invalid input" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<project name="kotlin_rules"> | |
<property environment="env"/> | |
<typedef resource="org/jetbrains/kotlin/ant/antlib.xml" classpath="${env.KOTLIN_HOME}/lib/kotlin-ant.jar"/> | |
<target name="-post-compile"> | |
<path id="project.javac.classpath"> | |
<path refid="project.all.jars.path" /> | |
<path refid="tested.project.classpath" /> | |
<path path="${java.compiler.classpath}" /> | |
<path path="${project.target.android.jar}"/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
use 5.010; | |
=pod | |
1. B<Don't use big words.> These people aren't very bright. Don't use words longer than 6 characters. Excludes punctuation. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%% -*- Prolog -*- | |
% A very simple "toothpicks" game in Prolog. Two players take turns | |
% drawing one, two, or three toothpicks from a stack. If you take the | |
% last one, then you lose. I made this late one night, mainly to prove | |
% to myself that game programming is actually possible in Prolog. | |
:- | |
use_module(library(readutil)). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Math Stuff for Silly Internet Math Person</title> | |
<script type="application/javascript"> | |
const WIDTH = 320; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
# Insanity in WUAS. | |
use strict; | |
use warnings; | |
use 5.010; | |
use Data::Dumper; |
OlderNewer