exam questions

Exam 70-483 All Questions

View all questions & answers for the 70-483 exam

Exam 70-483 topic 2 question 104 discussion

Actual exam question from Microsoft's 70-483
Question #: 104
Topic #: 2
[All 70-483 Questions]

DRAG DROP -
You are developing a C# application. The application includes a class named Rate. The following code segment implements the Rate class:

You define a collection of rates named rateCollection by using the following code segment:
Collection<Rate> rateCollection = new Collection<Rate>() ;
The application receives an XML file that contains rate information in the following format:

You need to parse the XML file and populate the rateCollection collection with Rate objects.
How should you complete the relevant code? (To answer, drag the appropriate code segments to the correct locations in the answer area. Each code segment may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.)
Select and Place:

Show Suggested Answer Hide Answer
Suggested Answer:

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
Kilsimon
Highly Voted 4 years, 6 months ago
Tested with code: reader.ReadToFollowing("rate") reader.MoveToFirstAttribute(); reader.MoveToNextAttribute(); reader.ReadToFollowing("value"); //This is the one with a different answer in a later question. This is the correct answer. Later in this set, the same question appears with a different answer. That is wrong - this is the correct way.
upvoted 16 times
Take2
4 years, 6 months ago
Thank you for letting us all know that! :)
upvoted 2 times
...
...
Denis1960
Most Recent 4 years, 5 months ago
All solutions are wrong because : Attribute order is not significant, though. <people> <person name="kathy" id="1"/> </people> This is exactly the same as: <people> <person id="1" name="kathy"/> </people> https://stackoverflow.com/questions/1131495/in-xml-is-order-important
upvoted 4 times
...
JoelChuca
4 years, 7 months ago
The code solution does not compile. If your remove the StreamReader instance, it works using (XmlReader reader = XmlReader.Create(rateXML))
upvoted 1 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago