Skip to content

Instantly share code, notes, and snippets.

View HennyH's full-sized avatar

Henry Hollingworth HennyH

View GitHub Profile
@HennyH
HennyH / abn_schema.xsd
Last active March 10, 2017 07:10
Australian Business Schema
<?xml version="1.0" encoding="UTF-8"?>
<!--
History:
April 2012: Added new value of BN to NameTypeEnum
Jan 2014: Tightened up definitions
Apr 2015: Added date of extract and main dgr
-->
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" targetNamespace="http://business">
<xsd:element name="Transfer">
<xsd:complexType>
@HennyH
HennyH / not_turning_on.ini
Last active June 7, 2021 08:56
Simple troubleshooter program.
[pc_wall]
root = true
text = Is the switch at the wall to which the computer power cable is conencted turned on?
if_no = switch_on (object:wall switch) (next:pc_psu)
if_yes = pc_psu
if_is_laptop = pc_light
if_they_dont_know = switch_on ()
[switch_on]
text = Have you turned ${object:the switch} on?
@HennyH
HennyH / common.py
Created June 8, 2021 00:11
Python Challenge (PERT + Word Puzzle)
from typing import List, NamedTuple
class Task():
def __init__(self, name: str, duration: int, depends_on: List['Task']):
self.name = name
self.duration = duration
self.depends_on = depends_on
def __str__(self):
return f"Task({self.name}, depends_on=({', '.join(t.name for t in self.depends_on)}))"