JSON: Difference between revisions

Content added Content deleted
(→‎{{header|Julia}}: use import rather than require, triple-quoted string for nicer nested quotes)
Line 1,091: Line 1,091:
The JSON module is installed by running Pkg_add("JSON").
The JSON module is installed by running Pkg_add("JSON").
<lang Julia>
<lang Julia>
julia> require("JSON")
julia> import JSON
julia> JSON.parse("{ \"blue\": [1,2], \"ocean\": \"water\" }")
julia> JSON.parse("""{ "blue": [1,2], "ocean": "water" }""")
["ocean"=>"water","blue"=>{1,2}]
["ocean"=>"water","blue"=>{1,2}]