Wrote a semi-functional word script