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
[{'Queue': 0, 'Writes': 0, 'WriteBytes': u'0', 'Name': u'C:'}, {'Queue': 0, 'Wri | |
tes': 0, 'WriteBytes': u'0', 'Name': u'D:'}, {'Queue': 0, 'Writes': 0, 'WriteByt | |
es': u'0', 'Name': u'E:'}, {'Queue': 0, 'Writes': 0, 'WriteBytes': u'0', 'Name': | |
u'_Total'}] | |
>>> |
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
from checks import AgentCheck | |
#from md5 import md5 | |
from multiprocessing import Process | |
import subprocess as sp | |
import time | |
import sys | |
import shlex | |
class LBMStat(AgentCheck): | |
def check(self, instance): |
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
// | |
// main.swift | |
// Bukimur | |
// | |
// Created by Rodrick Brown on 7/8/14. | |
// Copyright (c) 2014 Rodrick Brown. All rights reserved. | |
// | |
import Foundation |
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 random | |
class Rummikub(object): | |
decks = [0,1] | |
colors = ["red", "blue", "black", "orange"] | |
numbers = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13] | |
jokers = ["black", "red"] | |
bag = [] |
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
func dealTiles(n: Int) -> [Dictionary<String, AnyObject>]{ | |
var tiles: [Dictionary<String, AnyObject>] = [] | |
for i in 0...n-1 { | |
tiles.append(self.bag[i]) | |
self.bag.removeAtIndex(i) | |
} | |
//bag[bag.startIndex] | |
return tiles | |
} |
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
class SetValidation { | |
var sets: [Dictionary<String, AnyObject>] = [] | |
init(sets: [Dictionary<String, AnyObject>]) { | |
self.sets = sets | |
} | |
func validGroups(group: [Dictionary<String, AnyObject>]) -> Bool { | |
if group.count <= 0 { | |
return 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
// | |
// main.swift | |
// Bukimur | |
// | |
// Created by Rodrick Brown on 7/8/14. | |
// Copyright (c) 2014 Rodrick Brown. All rights reserved. | |
// | |
import Foundation |
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 random | |
def merge(left, right): | |
result = [] | |
i, j = 0,0 | |
while i < len(left) and j < len(right): | |
if left[i] <= right[j]: | |
result.append(left[i]) | |
i += 1 |
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
// | |
// main.swift | |
// Bukimur | |
//[Dictionary<String, String>] | |
// Created by Rodrick Brown on 7/8/14. | |
// Copyright (c) 2014 Rodrick Brown. All rights reserved. | |
// | |
import Foundation |
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
// | |
// main.swift | |
// Bukimur | |
// Copyright (c) 2014 Bukimur.io All rights reserved. | |
import Foundation | |
class Sets { | |
var sets = Array<Dictionary<String,Any>>() |
OlderNewer