Xcode

时间:2016-08-13 02:41:17

标签: xcode swift-playground

当我运行这个小代码时,我看不到结果。我只看到:(11次)

var name = "Karthik"

for x in 0...10 {
    print(name)
}

如何单独显示结果?

1 个答案:

答案 0 :(得分:2)

最初它看起来像这样 Initially it looks like this

选择快速查看图标 Select the quick look icon

它会弹出一个弹出窗口,您会看到一个值,右键单击它并选择值历史记录 It opens a pop up, you'll see one value, right click it on it and select value history

你会看到值列表并可以滚动它 YOu'll see the list of values and can scroll through it

尝试使用另一个选项,使用名为show result的眼睛图标。点击它 Try to use the other option with an eye like icon called show result. Click on it

您会在操场编辑器中看到结果弹出。 You'll see that the result popped itself on the playground editor.

右键单击弹出窗口,该弹出窗口现在位于操场编辑器中并选择值历史记录 Right click on the pop up which is now sitting in the playground editor and select value history

你会看到值列表并可以滚动它 YOu'll see the list of values and can scroll through it

希望这有助于:)