回答編集履歴

1

do

2016/01/12 14:12

投稿

fuzzball
fuzzball

スコア16731

test CHANGED
@@ -2,22 +2,50 @@
2
2
 
3
3
  ```swift
4
4
 
5
- _={
5
+ _ = {
6
6
 
7
- // fadeIn/Out
7
+ // fadeIn/Out
8
8
 
9
- let buf: [UInt8] = [
9
+ let buf: [UInt8] = [
10
10
 
11
- UInt8(colors[sequencePostCount][0]),
11
+ UInt8(colors[sequencePostCount][0]),
12
12
 
13
- :
13
+ :
14
14
 
15
- UInt8(colors[sequencePostCount][9])
15
+ UInt8(colors[sequencePostCount][9])
16
16
 
17
- ]
17
+ ]
18
18
 
19
19
  }()
20
20
 
21
21
  ```
22
22
 
23
23
  こんなのでどうですか?(動作未確認)
24
+
25
+
26
+
27
+ ■追記
28
+
29
+ 調べてたらこんなのを見つけました。ちょっとシンプル。
30
+
31
+ ```swift
32
+
33
+ do {
34
+
35
+ // fadeIn/Out
36
+
37
+ let buf: [UInt8] = [
38
+
39
+ UInt8(colors[sequencePostCount][0]),
40
+
41
+ :
42
+
43
+ UInt8(colors[sequencePostCount][9])
44
+
45
+ ]
46
+
47
+ }
48
+
49
+ ```
50
+
51
+