"return type required"

The error message says it all. You min method doesn't have a return type. Compare it to the main method or any other method for that matter.