Skip to content

Instantly share code, notes, and snippets.

View dannycjones's full-sized avatar

Daniel Carl Jones dannycjones

View GitHub Profile
<!DOCTYPE html>
<!--[if lt IE 7]><html class="lt-ie10 lt-ie9 lt-ie8 lt-ie7"><![endif]-->
<!--[if IE 7]><html class="lt-ie10 lt-ie9 lt-ie8"><![endif]-->
<!--[if IE 8]><html class="lt-ie10 lt-ie9"> <![endif]-->
<!--[if IE 9]><html class="lt-ie10"> <![endif]-->
<!--[if gt IE 9]><!--> <html> <!--<![endif]-->
<head>
{MobileAppHeaders}
<meta charset="utf-8">
<title>Redirecting...</title>
<!DOCTYPE html>
<html>
<head>
{MobileAppHeaders}
<meta charset="utf-8">
<title>{Title}</title>
{block:Description}
<meta name="description" content="{MetaDescription}"/>
{/block:Description}
console.info("specialRep Javascript Loaded.");
var specialRepUsers = [];
var specialRepInterval;
function UserObj(memberID, repMsg, background, prob) {
this.memberID = memberID;
this.repMessage = repMsg;
this.bgColor = background;
this.prob = prob;
/* Credit to https://gist.github.com/commadelimited/4958196 for the first section (slightly modified) */
function harlemShake() {
function c() {
var e = document.createElement("link");
e.setAttribute("type", "text/css");
e.setAttribute("rel", "stylesheet");
e.setAttribute("href", f);
e.setAttribute("class", l);
document.body.appendChild(e)
@dannycjones
dannycjones / euclids.rb
Last active June 2, 2016 08:13
An implementation of Euclid's algorithm in Ruby finding the highest common factor for two numbers.
def euclids(a, b) # Euclid's Algorithm
quotient = a / b
remainder = a % b # modulo
puts "#{a} = #{quotient}(#{b}) + #{remainder} [hcf(#{a}, #{b})]"
return b if remainder.zero?
euclids(b, remainder)
end
def hcf(a, b)
euclids(a, b)
fizzBuzz :: [Int] -> [String]
fizzBuzz listOfNumbers = [fizzify x | x <- listOfNumbers]
where
fizzify :: Int -> String
fizzify num
| fizz && buzz = "FizzBuzz"
| fizz = "Fizz"
| buzz = "Buzz"
| otherwise = show num
where fizz = num `mod` 3 == 0

Keybase proof

I hereby claim:

  • I am dannycjones on github.
  • I am dannycjones (https://keybase.io/dannycjones) on keybase.
  • I have a public key ASDEcdspZKj73gUaEZ40ryBrnpGmOZh0tJA_WpvR6Cnj1Ao

To claim this, I am signing this object:

Roles

President

The leader of the society. Tasked with setting the vision and leading strategic direction.

  • Always thinking ahead.
  • Always looking for opportunities to pursue. e.g. MLH have released a new workshop, how should we act on this?
  • ‎Always looking for ways to improve the society as a whole. What could we improve on for our next event?
  • Delegate across the committee as equally as possible, ensuring no one person is burdened with too much work.
@dannycjones
dannycjones / bp.yaml
Last active September 9, 2023 11:40
messing with blueprints, ignore
blueprint:
name: ZHA - Philips Hue Dimmer Switch - V2
description: |
Control lights with a Philips Hue Dimmer Switch.
The top "on" button behaviour is adjustable. By default it behaves like this:
- Press it while the light is off, and the light will turn on to the last set brightness.
- Press it again while the light is on, the light will turn to the fixed brightness setting.
Dim up/down buttons will change the brightness smoothly and can be pressed