nerdexam
Juniper

JN0-422 · Question #60

Click the Exhibit button. Exhibit: Referring to the exhibit, which Python statement selects the <user-entry> element for the user logged in on the pts/2 TTY?

The correct answer is B. response.find("./uptime-information/user-table/[tty='pts/2']/user-entry"). Explanation/Reference:

PyEZ

Question

Click the Exhibit button. Exhibit:

Referring to the exhibit, which Python statement selects the <user-entry> element for the user logged in on the pts/2 TTY?

Exhibit

JN0-422 question #60 exhibit

Options

  • Aresponse.find("./uptime-information/user-table/user-entry/tty='pts/2'")
  • Bresponse.find("./uptime-information/user-table/[tty='pts/2']/user-entry")
  • Cresponse.find("../user-entry/[tty='pts/2']")
  • Dresponse.find("./uptime-information/user-table/user-entry@tty='pts/2'")

How the community answered

(31 responses)
  • A
    3% (1)
  • B
    84% (26)
  • C
    3% (1)
  • D
    10% (3)

Explanation

Explanation/Reference:

Topics

#XPath#XML parsing#PyEZ#lxml

Community Discussion

No community discussion yet for this question.

Full JN0-422 Practice