3TDS - Programação Backend - Mapas
Quiz
•
Information Technology (IT)
•
12th Grade
•
Practice Problem
•
Hard
JOAO MONTEIRO
Used 1+ times
FREE Resource
Enhance your content in a minute
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Qual das seguintes afirmações sobre HashMap e TreeMap em Java é correta?
HashMap mantém os elementos ordenados pela ordem natural das chaves.
TreeMap mantém os elementos ordenados pela ordem natural das chaves.
HashMap e TreeMap não permitem chaves nulas.
TreeMap é mais rápido que HashMap para operações de inserção.
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
O que acontece se você tentar inserir uma chave nula em um TreeMap?
A chave nula é aceita normalmente.
O TreeMap substitui a chave nula pela string "null".
O TreeMap lança uma exceção NullPointerException.
O TreeMap ignora a inserção.
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Qual é a principal diferença de desempenho entre HashMap e TreeMap?
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Qual método pode ser usado para obter todas as chaves de um Map em Java?
map.values()
map.keySet()
map.getKeys()
map.entries()
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Sobre o uso de chaves e valores em um Map, qual das alternativas é verdadeira?
As chaves podem ser duplicadas, mas os valores não.
Os valores podem ser duplicados, mas as chaves não.
Nem chaves nem valores podem ser duplicados.
Tanto chaves quanto valores podem ser duplicados.
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Como criar um mapa imutável em Java a partir do Java 9?
Usando new HashMap<>()
Usando Map.of()
Usando map.clear()
Usando map.putAll()
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
O que acontece se você tentar modificar um mapa criado com Map.of()?
O mapa aceita a modificação normalmente.
O mapa lança uma exceção UnsupportedOperationException.
O mapa ignora a modificação.
O mapa substitui o valor antigo pelo novo.
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
15 questions
1ª compet 2º tec Polo
Quiz
•
12th Grade
15 questions
Understanding Computing Concepts
Quiz
•
12th Grade
10 questions
User Experience Research and Design Quiz
Quiz
•
12th Grade
15 questions
Uji Pengetahuan Teknologi Informasi
Quiz
•
12th Grade
15 questions
Quiz Jaringan Komputer dan Internet (Part - 2) XII
Quiz
•
12th Grade
10 questions
Dasar Koding dan Kecerdasan Artifisial
Quiz
•
12th Grade
5 questions
EtherChannel Quiz
Quiz
•
12th Grade
8 questions
3TDS - Programação Backend - Aula 12
Quiz
•
12th Grade
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
54 questions
Analyzing Line Graphs & Tables
Quiz
•
4th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
Discover more resources for Information Technology (IT)
20 questions
-AR -ER -IR present tense
Quiz
•
10th - 12th Grade
15 questions
Making Inferences
Quiz
•
7th - 12th Grade
12 questions
Add and Subtract Polynomials
Quiz
•
9th - 12th Grade
7 questions
How James Brown Invented Funk
Interactive video
•
10th Grade - University
15 questions
Atomic Habits: Career Habits
Lesson
•
9th - 12th Grade
20 questions
Banking
Quiz
•
9th - 12th Grade
15 questions
Exponential Growth and Decay Word Problems Practice
Quiz
•
9th - 12th Grade
18 questions
AP Bio Insta-Review Topic 6.1*: DNA & RNA Structure
Quiz
•
9th - 12th Grade
