Skip to content

Commit f210e74

Browse files
committed
script2 fixed
1 parent 85ffbc0 commit f210e74

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

jq/script-02.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,5 @@ set -euo pipefail
55
# The input for this script is the person.json file.
66
# TODO: Write a command to output the address of the person, all on one line, with a comma between each line.
77
# Your output should be exactly the string "35 Fashion Street, London, E1 6PX", but should not contain any quote characters.
8-
jq -r '.address[0] + ", " + .address[1]+ ", "+ .address[2]' person.json
8+
9+
jq -r '.address | join(", ")' person.json

0 commit comments

Comments
 (0)