Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

HashiCorp Exam VA-002-P Topic 10 Question 90 Discussion

Actual exam question for HashiCorp's VA-002-P exam
Question #: 90
Topic #: 10
[All VA-002-P Questions]

True or False:

Similar to how Vault works with databases and cloud providers, the Active Directory secrets engine dynamically generates the account and password for the requesting Vault client.

Show Suggested Answer Hide Answer
Suggested Answer: C

lookup retrieves the value of a single element from a map, given its key. If the given key does not exist, the given default value is returned instead. In this case, the function call is searching for the key 'c'. But since there is no key 'c', the default vault 'what?' is returned.

https://www.terraform.io/docs/configuration/functions/lookup.html


Contribute your Thoughts:

Lanie
10 months ago
Terraform, more like 'terrifying', am I right? Anyway, the answer is C. Unless the map is actually a mystical artifact that bends the laws of reality, in which case all bets are off.
upvoted 0 times
Shawana
9 months ago
I'm pretty sure it's C) what?
upvoted 0 times
...
Adolph
9 months ago
Really? I thought it was B) hello
upvoted 0 times
...
Art
9 months ago
No, it's actually A) goodbye
upvoted 0 times
...
Lucy
10 months ago
C) what?
upvoted 0 times
...
...
Virgie
11 months ago
This question is a real head-scratcher. I'm going to go with C and hope the terraform gods are feeling generous today.
upvoted 0 times
...
Fabiola
11 months ago
D, obviously. The function is returning the key 'c' since it's not found in the map. What kind of sorcery is this terraform thing anyway?
upvoted 0 times
Suzi
10 months ago
I think you're mistaken. The correct answer is 'what?' since the key 'c' is not in the map.
upvoted 0 times
...
Francene
10 months ago
No, it actually returns 'what?' because the key 'c' is not found in the map.
upvoted 0 times
...
...
Genevive
11 months ago
I agree with Ayesha, the function lookup will return the value associated with key 'c', which is 'goodbye'. So, the correct answer is A) goodbye.
upvoted 0 times
...
Ayesha
11 months ago
I think the result is 'goodbye' because the function lookup searches for the key 'c' in the map and returns the corresponding value, which is 'goodbye'.
upvoted 0 times
...
Kanisha
11 months ago
C) what?
upvoted 0 times
...
Paris
11 months ago
Hold up, is this a trick question? If the map doesn't have the key 'c', shouldn't it just return the default value 'what?'? I'm going with C.
upvoted 0 times
Teresita
10 months ago
Looks like we all agree on option C then.
upvoted 0 times
...
Dick
10 months ago
Yeah, that makes sense. Option C it is.
upvoted 0 times
...
Alpha
10 months ago
I agree, I'm going with option C as well.
upvoted 0 times
...
Emmett
10 months ago
I think it should return the default value 'what?' if the key 'c' is not found.
upvoted 0 times
...
...
Goldie
11 months ago
I think the answer is B. The function call is looking for the key 'c', but the map only has keys 'a' and 'b', so it should return the value for 'a', which is 'hello'.
upvoted 0 times
...
Suzan
11 months ago
The result is clearly C. 'what?' is the default value returned when the key 'c' is not found in the map.
upvoted 0 times
Nathan
10 months ago
Oh, I see. So 'what?' is the default value if the key is not found.
upvoted 0 times
...
Leota
10 months ago
No, it's actually A) goodbye
upvoted 0 times
...
Vannessa
10 months ago
I think the answer is C) what?
upvoted 0 times
...
Celestine
10 months ago
Oh, I see. 'what?' is the default value if the key 'c' is not found.
upvoted 0 times
...
Verona
11 months ago
No, it's actually A) goodbye.
upvoted 0 times
...
Jina
11 months ago
I think the answer is C) what?
upvoted 0 times
...
...
Genevive
12 months ago
B) hello
upvoted 0 times
...
Ayesha
12 months ago
A) goodbye
upvoted 0 times
...

Save Cancel