質問編集履歴

2

文字列に修正

2021/04/23 09:05

投稿

meron88
meron88

スコア50

test CHANGED
File without changes
test CHANGED
@@ -16,7 +16,7 @@
16
16
 
17
17
  ```
18
18
 
19
- a = [{id: 3, code: A0003},{id: 2, code: A0002},{id: 1, code: A0001},]
19
+ a = [{id: 3, code: "A0003"},{id: 2, code: "A0002"},{id: 1, code: "A0001"},]
20
20
 
21
21
  ```
22
22
 
@@ -24,7 +24,7 @@
24
24
 
25
25
  ```ここに言語を入力
26
26
 
27
-    let a = [{id: 1, code: A0001},{id: 3, code: A0003},{id: 2, code:     A0002}];
27
+    let a = [{id: 1, code: "A0001"},{id: 3, code: "A0003"},{id: 2, code: "A0002"}];
28
28
 
29
29
 
30
30
 

1

修正しました

2021/04/23 09:05

投稿

meron88
meron88

スコア50

test CHANGED
File without changes
test CHANGED
@@ -24,6 +24,10 @@
24
24
 
25
25
  ```ここに言語を入力
26
26
 
27
+    let a = [{id: 1, code: A0001},{id: 3, code: A0003},{id: 2, code:     A0002}];
28
+
29
+
30
+
27
31
  let code = a.map((a) =>{
28
32
 
29
33
  return{ code: a.code, ...a}