Skip to content

Instantly share code, notes, and snippets.

View phantamanta44's full-sized avatar

phantamanta44

View GitHub Profile
/**
* Implemented by classes with finite cardinality.
*/
interface Finite {
// NO-OP
}
/**
* A class that cannot have an instance.
*/
(define (batch-autocrop pattern)
(let* ((filelist (cadr (file-glob pattern 1))))
(while (not (null? filelist))
(let* ((filename (car filelist))
(image (car (gimp-file-load RUN-NONINTERACTIVE filename filename)))
(width (car (gimp-image-width image)))
(height (car (gimp-image-height image)))
(layer (car (gimp-layer-new image width height INDEXEDA-IMAGE "temp" 100 NORMAL-MODE))))
(gimp-image-insert-layer image layer 0 0)
(let* ((layers (gimp-image-get-layers image))
mc.name: Eve
video: COlXAgQ6Cu0
members: seven, yoosung, jaehee, zen
---
seven: cats are just very small very furry humans
yoosung: wtf
^
i think he's onto something..
yoosung: MC wtf
wtf
#
# Cool bash prompt
# Modified verison of a dotfile by Artem Sapegin, sapegin.me
# ...which was originally inspired by: https://github.com/sindresorhus/pure
#
# You'll want to add the following to your bashrc to make this work properly:
#
# RED="$(tput setaf 1)"
# GREEN="$(tput setaf 2)"
# YELLOW="$(tput setaf 3)"
import java.util.function.*;
public class Throwing {
public static Runnable runnable(TRunnable f) {
return f;
}
@FunctionalInterface interface TRunnable extends Runnable {
void doRun() throws Exception;
{
"0": 6,
"1": 6,
"2": 6,
"3": 6,
"4": 6,
"5": 6,
"6": 6,
"7": 6,
"8": 6,
int truth(string msg) {
print(msg);
return 1;
}
int fizz(int i) => i % 3 == 0 ? truth('fizz') : 0;
int buzz(int i) => i % 5 == 0 ? truth('buzz') : 0;
void fizzbuzz(List<String> args) {
for (int i = 0; i < 100; i++) {
@phantamanta44
phantamanta44 / FizzBuzz.java
Created May 8, 2017 20:34
sort of inefficient fizzbuzz implementation in java
public class FizzBuzz {
public static void main(String[] args) {
for (int i = 0; i < args.length; i++) {
int n = Integer.parseInt(args[i]);
String out = ((n % 3) == 0 ? "Fizz" : "") + ((n % 5) == 0 ? "Buzz" : "");
System.out.println(out.isEmpty() ? Integer.toString(n) : out);
}
}
}
#pragma config(Sensor, in1, l, sensorReflection)
#pragma config(Motor, port1, f, tmotorVexFlashlight, openLoop, reversed)
#pragma config(Motor, port2, g, tmotorServoStandard, openLoop)
#pragma config(Motor, port3, b, tmotorServoStandard, openLoop)
//*!!Code automatically generated by 'ROBOTC' configuration wizard !!*//
// CONFIG
int kBinSteel = 100; // The servo angle for the steel marble bin
int kBinYellow = -80; // The servo angle for the yellow marble bin
@phantamanta44
phantamanta44 / empoleon-drill-peck.txt
Created February 8, 2017 16:56
EMPOLEON, USE DRILL PECK
DRILL PECK I (Empoleon) @ Sharp Beak
Ability: Defiant
EVs: 252 Atk / 252 Spe
Adamant Nature
- Drill Peck
- Drill Peck
- Drill Peck
- Drill Peck
DRILL PECK II (Empoleon) @ Sharp Beak