回答編集履歴
1
追記
test
CHANGED
@@ -2,8 +2,16 @@
|
|
2
2
|
|
3
3
|
|
4
4
|
|
5
|
+
```awk
|
6
|
+
|
7
|
+
echo '123456,abc||def||gh' | awk -F ',|\|\|' '{for (i=2; i<=NF; i++){printf "%s,%s\n",$1,$i}}'
|
8
|
+
|
5
9
|
```
|
6
10
|
|
11
|
+
|
12
|
+
|
13
|
+
```perl
|
14
|
+
|
7
|
-
echo '123456,abc||def||gh' |
|
15
|
+
echo '123456,abc||def||gh' | perl -F',|\|\|' -anle 'for (@F[1..$#F]){printf "%s,$_\n",$F[0]}'
|
8
16
|
|
9
17
|
```
|