ExamGecko
Question list
Search
Search

List of questions

Search

Related questions











Question 31 - 300-910 discussion

Report
Export

Refer to the exhibit.

The exhibit shows the output of an Ansible task that prints the contents of the show_ip_int_brief variable that was registered in a different task in the playbook.

Which expression is used to print the output of the command without its header row?

A.

show_ip_int_brief[‘stdout_lines’][0]

Answers
A.

show_ip_int_brief[‘stdout_lines’][0]

B.

show_ip_int_brief[‘stdout_lines’][1:]

Answers
B.

show_ip_int_brief[‘stdout_lines’][1:]

C.

show_ip_int_brief[‘stdout_lines’][0][1:]

Answers
C.

show_ip_int_brief[‘stdout_lines’][0][1:]

D.

show_ip_int_brief[‘stdout_lines’]

Answers
D.

show_ip_int_brief[‘stdout_lines’]

Suggested answer: C

Explanation:

--- show_ip_int_brief["˜stdout_lines'][0][1:] --- stdout_lines - nested list, [0], first element of above nested list (extract of all header + interfaces, coma separated for individual elements), [1:] - 2nd, 3rd, 4th line of the above sub-list.

asked 10/10/2024
Fabio Zannetti
36 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first