make gitbook
This commit is contained in:
@ -21,8 +21,8 @@
|
||||
<link rel="prev" href="../chapter2/04_Collection_Types.html" />
|
||||
|
||||
|
||||
<meta property="og:title" content="控制流 | 这一次,让中国和世界同步">
|
||||
<meta property="og:site_name" content="这一次,让中国和世界同步">
|
||||
<meta property="og:title" content="控制流 | Swift 编程语言">
|
||||
<meta property="og:site_name" content="Swift 编程语言">
|
||||
<meta property="og:type" content="book">
|
||||
<meta property="og:locale" content="en_US">
|
||||
|
||||
@ -46,7 +46,7 @@
|
||||
|
||||
|
||||
|
||||
<div class="book" data-level="2.5" data-basepath=".." data-revision="1402523087598">
|
||||
<div class="book" data-level="2.5" data-basepath=".." data-revision="1402550478518">
|
||||
<div class="book-header">
|
||||
<!-- Actions Left -->
|
||||
<a href="#" class="btn pull-left toggle-summary" aria-label="Toggle summary"><i class="fa fa-align-justify"></i></a>
|
||||
@ -98,7 +98,7 @@
|
||||
<!-- Title -->
|
||||
<h1>
|
||||
<i class="fa fa-spinner fa-spin"></i>
|
||||
<a href="../" >这一次,让中国和世界同步</a>
|
||||
<a href="../" >Swift 编程语言</a>
|
||||
</h1>
|
||||
</div>
|
||||
|
||||
@ -587,10 +587,10 @@
|
||||
|
||||
<div class="page-inner">
|
||||
|
||||
<section class="normal" id="section-gitbook_6479">
|
||||
<section class="normal" id="section-gitbook_106">
|
||||
|
||||
<blockquote>
|
||||
<p>翻译:vclwei, @coverxit, @NicePiao</p>
|
||||
<p>翻译:vclwei, coverxit, NicePiao</p>
|
||||
<p>校对:coverxit</p>
|
||||
</blockquote>
|
||||
<h1 id="-">控制流</h1>
|
||||
@ -599,10 +599,8 @@
|
||||
<ul>
|
||||
<li><a href="#for_loops">For 循环</a></li>
|
||||
<li><a href="#while_loops">While 循环</a></li>
|
||||
<li><p><a href="#conditional_statement">条件语句</a></p>
|
||||
</li>
|
||||
<li><p><a href="#control_transfer_statements">控制传递语句(Control Transfer Statements)</a></p>
|
||||
</li>
|
||||
<li><a href="#conditional_statement">条件语句</a></li>
|
||||
<li><a href="#control_transfer_statements">控制传递语句(Control Transfer Statements)</a></li>
|
||||
</ul>
|
||||
<p>Swift提供了类似 C 语言的流程控制结构,包括可以多次执行任务的<code>for</code>和<code>while</code>循环,基于特定条件选择执行不同代码分支的<code>if</code>和<code>switch</code>语句,还有控制流程跳转到其他代码的<code>break</code>和<code>continue</code>语句。</p>
|
||||
<p>除了 C 语言里面传统的for条件递增(<code>for-condition-increment</code>)循环,Swift 还增加了<code>for-in</code>循环,用来更简单地遍历数组(array),字典(dictionary),区间(range),字符串(string)和其他序列类型。</p>
|
||||
|
||||
Reference in New Issue
Block a user