Creating an IntelliJ Project Flashcards
What does a project in IntelliJ serve as?
a) A collection of unrelated Java programs
b) A wrapper around related Java programs
c) A template for Android applications
d) A project for Version Control System management
b) A wrapper around related Java programs
What is the first step to initialize a new Java project in IntelliJ?
a) Open an existing project
b) Create a new template
c) Select ‘New Project’
d) Get a project from Version Control
c) Select ‘New Project’
What folder will contain the Java source files in the project structure?
a) .idea folder
b) Source folder
c) Workspace folder
d) IntelliJ Module folder
b) Source folder
What kind of file is created to write the first Java program?
a) Kotlin Class
b) XML file
c) Java Class file
d) Configuration file
c) Java Class file
What is the purpose of the .idea folder in IntelliJ projects?
a) It contains the Java source files
b) It is used for IntelliJ’s internal configuration
c) It stores project libraries
d) It holds project version history
b) It is used for IntelliJ’s internal configuration
What happens after selecting a plain Java Class in IntelliJ?
a) You are prompted to enter the name of your Java Class
b) You are asked to choose between multiple project templates
c) The program is automatically compiled
d) A Version Control System is initialized
a) You are prompted to enter the name of your Java Class
What is the convention for naming a class in Java?
a) It should start with a number
b) It should contain spaces between words
c) It should begin with an uppercase letter and follow Pascal case
d) It must use all lowercase letters
c) It should begin with an uppercase letter and follow Pascal case
What is required for the name of a Java class and the source file?
a) They must always be different
b) They can be different if using the Java 15 SDK
c) They must match exactly
d) They only need to match if there is more than one class
c) They must match exactly
What does the first line of the Java source file indicate?
a) The creation of a method
b) The end of a class definition
c) The start of a class definition
d) The declaration of a variable
c) The start of a class definition
What characters can be used in a Java class name?
a) Only alphabets and spaces
b) Alphabets, numbers, underscores, and dollar signs
c) Only alphabets and numbers
d) Alphabets, numbers, and hyphens
b) Alphabets, numbers, underscores, and dollar signs
What is the purpose of the opening and closing curly braces in a Java class?
a) To enclose the class definition
b) To declare a variable
c) To separate different methods
d) To initialize the main method
a) To enclose the class definition