Reformatted code (uniform single-quotes and else clauses), and added inventory declaration at top