Review the code.
var capitalCities = [ " USA " : " Washington D.C. " , " Spain " : " Madrid " , " Peru " : " Lima " ] Which two statements add the capital city of " Italy " to the dictionary? (Choose 2.)
A. capitalCities = capitalCities + [ " Italy " : " Rome " ]
B. capitalCities.updateValue( " Rome " , forKey: " Italy " )
C. capitalCities.append([ " Italy " : " Rome " ])
D. capitalCities[ " Italy " ] = " Rome "
E. capitalCities[ " Rome " ] = " Italy "
正解:B,D
質問 2:
Given the function definition, which two statements call the function correctly? (Choose 2.)

Based on the image provided, here is the text for each of the multiple-choice options:
A. E. schedule(who: " Jane Doe " , from: " 9:30am " , to: " 10:30am " )
B. D. schedule(name: " Jane Doe " , starting: " 9:30am " , ending: " 10:30am " , place: " Office " )
C. schedule(who: " Jane Doe " , from: " 9:30am " , to: " 10:30am " , " Office " )
D. schedule(who name: " Jane Doe " , from starting: " 9:30am " , to ending: " 10:30am " )
E. schedule(who: " Jane Doe " , from: " 9:30am " , to: " 10:30am " , place: " Office " )
正解:A,D
解説: (Pass4Test メンバーにのみ表示されます)
質問 3:
Review the code.
Note: You might need to scroll to see the entire block of code.

A breakpoint is set on line 3. When the application is run. it will stop at line 3. You need to debug the code.
Drag each debugging control from the left to the correct instruction on the right. You will receive partial credit for each correct answer

正解:

Explanation:
This question belongs to Xcode Developer Tools , especially the objective on using debugging techniques including breakpoints and stepping controls .
When execution stops at a breakpoint on line 3, Step Over runs that line without entering into another function call, so it is the correct action for moving past line 3 while staying in the current function. Step Into is used when execution reaches line 4 and you want to enter the display(numbers) function, which takes you into the function body starting at line 8. Once inside that function, Step Out continues execution until the current function returns, which is exactly what "step out from line 8" means.
Deactivate breakpoints turns breakpoint handling off so the debugger no longer stops on active breakpoints.
Continue program execution resumes the app until the next breakpoint or until the program finishes.
So the correct control order is:
1 = Continue
2 = Deactivate breakpoints
3 = Step Over
4 = Step Into
5 = Step Out

質問 4:
Given the function, which two function calls are valid? (Choose 2.)

A. let sun = rightSum(numl: 100, num2: 50)
B. let sum = rightSum(100, num2: SO, and: 20)
C. let sum - rightSum(100, by: 30, and: 20)
D. let Sun - rightSum(numl: 100, by: SO, and: SO)
E. let sum r\ ght5um(100, by: 50)
正解:C,E
解説: (Pass4Test メンバーにのみ表示されます)
質問 5:
Review the code:

Given a struct called Animal, what line of code should be added on line 5 in order to produce the output shown?

A. Text(animal.name)
B. Text(animals[animal].name)
C. Text(Animal.name)
D. Text(Animals[animal].name)
正解:A
解説: (Pass4Test メンバーにのみ表示されます)
901 お客様のコメント









Shibata -
Pass4TestのApp-Development-with-Swift-Certified-Userの問題集を習得して本場試験に合格した。しかも高得点。次は9L0-005に挑戦したいと思います!