This file contains hidden or 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
/** | |
* @file Jasteroids.java -- Simple Java Asteroids game. | |
* | |
* This file is self-contained using only dependencies built-into the | |
* standard java platform. | |
*/ | |
import java.util.ArrayList; | |
import java.util.Random; | |
import javax.swing.JFrame; | |
import javax.swing.JComponent; |
This file contains hidden or 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
/*===-- small_pt.c - Kevin Beason's Small Path Tracer in C99 --------------===*/ | |
/* This is a pure C99 implementation of Kevin Beason's small path tracer | |
* originally written in 99 lines of C++. This version does not aim to | |
* minimize lines of code (although it does adhere to a strict 80 column | |
* limit). | |
* | |
* This source is released under the MIT license, which is open and | |
* compatible with GPL. See https://opensource.org/licenses/MIT. | |
* |
This file contains hidden or 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
/*===-- bf.c - BrainF*ck Interpreter --------------------------------------===*/ | |
/* Notes: | |
* Bog standard BrainF*ck compliant interpreter. Uses a table to store jump | |
* addresses for loop return and escape. | |
* | |
* Language Ref: | |
* > Increment data pointer. | |
* < Decrement data pointer. | |
* + Increment (byte) value at data pointer. |
This file contains hidden or 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
# <Project Name> GitIgnore | |
# Created by https://www.gitignore.io/api/c++,cmake,emacs,intellij,linux,osx | |
# Build ----------------------------------------------------------------------- | |
### Output and Cache Directories ### | |
/External/ | |
/Debug/ | |
/Docs/ | |
/Release/ |
This file contains hidden or 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
;; Given a cipher sum | |
;; THREE | |
;; THREE | |
;; FOUR | |
;; ONE | |
;; ______ | |
;; ELEVEN | |
;; Calculate the cipher. |
This file contains hidden or 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
snow 1.0000 0.9804 0.9804 | |
ghost-white 0.9725 0.9725 1.0000 | |
GhostWhite 0.9725 0.9725 1.0000 | |
white-smoke 0.9608 0.9608 0.9608 | |
WhiteSmoke 0.9608 0.9608 0.9608 | |
gainsboro 0.8627 0.8627 0.8627 | |
floral-white 1.0000 0.9804 0.9412 | |
FloralWhite 1.0000 0.9804 0.9412 | |
old-lace 0.9922 0.9608 0.9020 | |
OldLace 0.9922 0.9608 0.9020 |
This file contains hidden or 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
/** | |
* sdl2_opengl.cpp | |
* Minimal OpenGL Demo using SDL2.0 | |
* from: https://gist.github.com/exavolt/2360410 | |
*/ | |
#include <iostream> | |
#include <string> | |
#include <SDL2/SDL.h> | |
#include <SDL2/SDL_opengl.h> |
This file contains hidden or 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
(defn fizzbuzz [n] | |
(cond (zero? (rem n 15)) "FizzBuzz" | |
(zero? (rem n 5)) "Buzz" | |
(zero? (rem n 3)) "Fizz" | |
:else n)) | |
(def fizzbuzz-seq | |
(for [x (iterate inc 1)] | |
(fizzbuzz x))) |
This file contains hidden or 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
module Main where | |
-- Infinite fizzbuzz sequence. | |
fizzbuzz :: [String] | |
fizzbuzz = [convert x | x <- [1..]] | |
where | |
convert s | |
| s `mod` 15 == 0 = "FizzBuzz" | |
| s `mod` 5 == 0 = "Buzz" | |
| s `mod` 3 == 0 = "Fizz" |
This file contains hidden or 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 -w | |
# The Perl Speaking Alarm CLock | |
# Author: Stuart Hacking <stuhacking_AT_gmail.com> | |
# Version: 0.2 | |
# Speaks a mixture of early morning greetings to gently encourage the | |
# user to wake up. Volume increases each time a certain number of | |
# iterations passes. phrases and names can be customized individually. | |
# Makes use of OS X commands for speech and volume control. Similar |
NewerOlder