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
// by Erik Wrenholt | |
import java.util.*; | |
class Mandelbrot | |
{ | |
static int BAILOUT = 16; | |
static int MAX_ITERATIONS = 1000; | |
private static int iterate(float x, float y) | |
{ |
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
<?php | |
define('CRLF', "\r\n"); | |
class HaveToWork extends Thread { | |
protected $wait; | |
public $socket = null; | |
public function __construct() { | |
$this->wait = true; | |
$this->start(); | |
} | |
public function run() { |
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
<?php | |
class jPrototype { | |
protected static $prototype = array(); | |
public static function prototype() { | |
if ( !self::$prototype ) { | |
self::$prototype = new self(); | |
} | |
return self::$prototype; | |
} | |
public function __set($property, $value) { |
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
<?php | |
/** | |
* An array merging helper | |
* @params array $original | |
* @params array $additionnal | |
* @return array | |
*/ | |
function merge_array( $original, $additionnal ) | |
{ | |
if ( empty($additionnal) ) return $original; |