Ideally, a string with an integer value should be passed to parseInt() method. So, on passing “Hello†an exception called “NumberFormatException†occurs since the parseInt() method cannot convert the given string “Hello†into an integer value.