Revature Interview questions with Correct Answers
What is CSS and how does it work? Correct Answer-Cascading style
sheets. It styles the website by describing how the HTML elements are
to be displayed.
What is MVC? Correct Answer-Model View Controller
it consists of three parts"
one that is the visual part that users interact with - the view,
one that represents the object being modeled, and
something that manages data between the different parts - the controller.
What are selectors? List some Correct Answer-Patterns used to select
the element you want to change. .class, #id, :visited.
How can you open a link in a new tab/browser window? Correct
Answer-<a href="url" target="_blank">
What is the correct HTML for making a drop-down list? Correct
Answer-the <select> element
, What is the javascript syntax to change an element of an HTML page?
Correct Answer-document.getElementById("demo").innerHTML =
"Hello World!";
What is a list, set, and map? When should you use each? Correct
Answer-List interface is a ordered collection that allows duplicate and
null values. We can get elements by index.
When there is a need to access elements frequently using the index, or
when you want the elements stored to maintain the insertion order then
use list.
A Set is an unordered collection that won't allow duplicate elements. It
allows null elements, but we can't get elements by key or index .
When the collection should be of unique elements and no duplicates are
tolerated, then go with "Set"
.
Map interface is a unordered collection that allows duplicate elements
but not duplicate keys. It allows null elements but not null keys.
When the data stored should be in the form of key and value then use
map.
Why doesn't java support multiple inheritance? Correct Answer-It
supports it, just through interfaces. It doesn't support multiple
inheritance in order to avoid the complexity and conflicts that result. For
What is CSS and how does it work? Correct Answer-Cascading style
sheets. It styles the website by describing how the HTML elements are
to be displayed.
What is MVC? Correct Answer-Model View Controller
it consists of three parts"
one that is the visual part that users interact with - the view,
one that represents the object being modeled, and
something that manages data between the different parts - the controller.
What are selectors? List some Correct Answer-Patterns used to select
the element you want to change. .class, #id, :visited.
How can you open a link in a new tab/browser window? Correct
Answer-<a href="url" target="_blank">
What is the correct HTML for making a drop-down list? Correct
Answer-the <select> element
, What is the javascript syntax to change an element of an HTML page?
Correct Answer-document.getElementById("demo").innerHTML =
"Hello World!";
What is a list, set, and map? When should you use each? Correct
Answer-List interface is a ordered collection that allows duplicate and
null values. We can get elements by index.
When there is a need to access elements frequently using the index, or
when you want the elements stored to maintain the insertion order then
use list.
A Set is an unordered collection that won't allow duplicate elements. It
allows null elements, but we can't get elements by key or index .
When the collection should be of unique elements and no duplicates are
tolerated, then go with "Set"
.
Map interface is a unordered collection that allows duplicate elements
but not duplicate keys. It allows null elements but not null keys.
When the data stored should be in the form of key and value then use
map.
Why doesn't java support multiple inheritance? Correct Answer-It
supports it, just through interfaces. It doesn't support multiple
inheritance in order to avoid the complexity and conflicts that result. For