无码av一区二区三区无码,在线观看老湿视频福利,日韩经典三级片,成 人色 网 站 欧美大片在线观看

歡迎光臨散文網(wǎng) 會員登陸 & 注冊

iOS移動應(yīng)用程序開發(fā) | 第二講-變量、常量和數(shù)據(jù)類型:Swift by Na

2023-01-08 11:34 作者:陳鵬宇老師  | 我要投稿

?
01:33:33
?

第二次作業(yè)

作業(yè)一:完成Playgrounds App《學(xué)習(xí)編程1》4-7章


作業(yè)二:完成下面的練習(xí)題

1. Consider the following array, containing a collection of our favorite pizzas:

Create a new Playground and write some code to do the following:

(i) Create this array, as a variable, storing the pizza names in it.

(ii) Print the element of the array that contains "Vegetarian".

(iii) Append the pizza "Pepperoni" to the array, without changing the rest of the array.

(iv) Insert a new pizza, "Ham, Pineapple, and Pesto", at index 2, shuffling everything after along by one index.

(v) Remove the "Cheese" pizza from the array entirely, leaving the rest intact.

(vi) Swap the "Prosciutto" pizza for a "Pumpkin and Feta" pizza, without changing the rest of the array.

(vii) Print out the whole array.


2. Consider the following questions about sets, and see if you can figure out the answer. Then run them in a Playground to find out.

(i)

What would be printed?

(ii)

What’s in this collection?

(iii)

What’s in this set?

(iv)

What does forbiddenPizzas contain now?


3. Consider the following dictionary, representing a bunch of dessert pizzas and the quantities that have been ordered:

Using Swift code, print the quantity of Rocky Road, and the quantity of Caramel Swirl. And then add a new order for 17 Banana Split pizzas.

iOS移動應(yīng)用程序開發(fā) | 第二講-變量、常量和數(shù)據(jù)類型:Swift by Na的評論 (共 條)

分享到微博請遵守國家法律
乐山市| 宁安市| 平乡县| 册亨县| 曲周县| 轮台县| 沙坪坝区| 聊城市| 兰溪市| 株洲市| 安吉县| 平乡县| 威远县| 长乐市| 图片| 仁怀市| 治多县| 平顶山市| 万盛区| 灵山县| 南汇区| 龙里县| 瓦房店市| 噶尔县| 高淳县| 宜黄县| 镇康县| 梅河口市| 理塘县| 青田县| 天柱县| 土默特左旗| 云浮市| 札达县| 泽州县| 句容市| 乡城县| 清丰县| 瓮安县| 白银市| 东城区|