public static String onKeyPress(String key){
  pin=pin.concat(key);
  return pin;
}

public static String onKeyPress ( String key ) { pin = pin . concat ( key ) ; return pin ; }
getting the value of key pressed and appending it to current pin
