I could be wrong, but I see that you used the Scanner:
"Scanner scan = new Scanner(System.in);"

Don't you have to import "java.util.*" ?