Inverse of a Matrix Matrix Inverse Multiplicative Inverse of a Matrix
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
/** | |
* @author bendem | |
*/ | |
public abstract class AbstractRepeatingTask implements Runnable { | |
private final long time; | |
private long delay = 0; | |
private final Thread thread; | |
private volatile boolean cancelled = false; | |
private volatile boolean idling = false; |
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
a = '0f69b410ccc810c9450186a010eff110f05510ccc910c8eb10ccd30186a010c8ea10effa10cd3710f05f10cd360186a010c94e10cd3710f3d80186a010ccd210f05510cd2d10eff010effb0186a010cd3710f05e10c94510effa0186a010f05410ccc810c9450186a010cd2c10c8e110f3e210f3d90186a010c94410cd3710c94f018af6' | |
def split(s, size): | |
return [s[i:i+size] for i in range(0, len(s), size)] | |
c = ''.join([chr(int(str(int(c, 16)), 2)) for c in split(a, 6)]) | |
print(c) |
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 os | |
import sys | |
class parser: | |
def __init__(self, filename): | |
self.imports = {} | |
self.filename = filename | |
def classfromimport(self, imp): |
I hereby claim:
- I am bendem on github.
- I am bendem (https://keybase.io/bendem) on keybase.
- I have a public key whose fingerprint is ECFA 8E8B 156C 58EA DAE7 EEE6 C743 CE8A AC8A 8DD3
To claim this, I am signing this object:
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> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>Glowstone Testing</title> | |
<!--<script src="/bundles/modernizr?v=qVODBytEBVVePTNtSFXgRX0NCEjh9U_Oj8ePaSiRcGg1"></script>--> | |
<!--<link rel="stylesheet" href="/Content/css/Glowstone.css">--> | |
<link rel="stylesheet" href="style.css"> | |
<script src="http://glowstone.turt2live.com/bundles/jquery?v=JzhfglzUfmVF2qo-weTo-kvXJ9AJvIRBLmu11PgpbVY1"></script> |
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
package be.bendem.testing.utils; | |
public class ColorUtils { | |
private ColorUtils() {} | |
public static int[] decompose(int color) { | |
int[] rgb = new int[3]; | |
rgb[0] = color >> 16 & 0xFF; |
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
// Simple ajax thing to send stuff | |
// @param url string | |
// @param success callback | |
// @param method string (optional) | |
// @param data plainobject (optional) | |
function ajax(url, success, method, data) { | |
var xhr = new XMLHttpRequest(); | |
// Set the callback to use when all the stuff is done | |
xhr.onreadystatechange = function() { | |
// We are not interested in the 3 other stages |
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
var Enum = function(values, methods) { | |
var created = {}; | |
var EnumValue = function(value) { | |
this.value = value; | |
} | |
if(methods) { | |
for(var name in methods) { | |
EnumValue.prototype[name] = methods[name]; | |
} |
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
mount="/home/bendem/nas-samba" | |
d=`date +"%H:%M:%S %d-%m-%Y"` | |
echo "Backup task running $d" | |
# Skip if not mounted | |
grep -qs "$mount" /proc/mounts | |
if [ $? -ne 0 ]; then | |
echo "Skipping..." | |
exit |
OlderNewer