Add some helper methods to Code.java

Helper methods added: getPin & match