MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/itsaunixsystem/comments/nxcfav/startup_welcome_to_javascript_writer_java_code/h1gwqnm/?context=3
r/itsaunixsystem • u/Worse_Username • Jun 11 '21
29 comments sorted by
View all comments
Show parent comment
14
Also, why "import java.util.Scanner;" to next line "import java.util.*;"?
Seems redundant
7 u/filtoid Jun 12 '21 Best to make sure the rest of the code knows that Scanner is more important because it was imported first. That way it can rule the other objects as a parent, the other imports are just children. This is how class heirarchy and inheritance works./s
7
Best to make sure the rest of the code knows that Scanner is more important because it was imported first. That way it can rule the other objects as a parent, the other imports are just children. This is how class heirarchy and inheritance works.
/s
View all comments
Show parent comment
14
u/[deleted] Jun 12 '21
Also, why "import java.util.Scanner;" to next line "import java.util.*;"?
Seems redundant