I have found many tutorials on JSON formatting, but cannot find the issue with my JSON. Can someone take a look and tell me where it is broken?
The goal is to have 3 different scenarios where a user picks answers to a test based on one of the 3 acuity divisions.
Each acuity section has 4 subsections, and each subsection has its own answers.
{"acuity1":
{"sec1":
{
"ans1": {"\ue01b"},
"ans2":{"\ue01b"},
"ans3": {"\ue01b"},
"ans4": {"\ue01b"},
"ans5": {"\ue01b"},
"ans6": {"\ue01b"},
"ans7": {"\ue01b"},
"ans8": {"\ue01b"},
"ans9": {"\ue01b"},
"ans10": {"\ue01b"},
"ans11": {"\ue01b"},
"ans12": {"\ue01b"},
"ans13": {"\ue01b"},
"ans14": {"\ue01b"},
"ans15": {"\ue01b"},
"ans16": {"\ue01f"},
"ans17": {"\ue01f"},
"ans18": {"\ue01f"},
"ans19": {"\ue01f"},
"ans20": {"\ue01f"},
"ans21": {"\ue01f"},
"ans22": {"\ue01f"},
"ans23": {"\ue01f"},
"ans24": {"\ue01f"},
"ans25": {"\ue01f"},
"ans26": {"\ue01f"},
"ans27": {"\ue01f"},
"ans28": {"\ue01f"},
"ans29": {"\ue01f"},
"ans30": {"\ue01f"},
"ans31": {"\ue01f"},
"ans32": {"\ue01f"},
"ans33": {"\ue01f"},
"ans34": {"\ue01f"},
"ans35": {"\ue01f"}
}
},
{"sec2":
{
"ans1":1 {"\ue01b"},
"ans2": {"\ue01b"},
"ans3": {"\ue01b"},
"ans4": {"\ue01b"},
"ans5": {"\ue01b"},
"ans6": {"\ue01b"},
"ans7": {"\ue01b"},
"ans8": {"\ue01b"},
"ans9": {"\ue01f"},
"ans10": {"\ue01f"},
"ans11": {"\ue01f"},
"ans12": {"\ue01f"},
"ans13": {"\ue01f"},
"ans14": {"\ue01f"},
"ans15": {"\ue01f"},
"ans16": {"\ue01f"}
}
},
{"sec3":
{
"ans1": {"\ue01b"},
"ans2": {"\ue01b"},
"ans3": {"\ue01b"},
"ans4": {"\ue01b"},
"ans5": {"\ue01b"},
"ans6": {"\ue01b"},
"ans7": {"\ue01b"},
"ans8": {"\ue01b"},
"ans9": {"\ue01b"},
"ans10": {"\ue01b"},
"ans11": {"\ue01f"},
"ans12": {"\ue01f"},
"ans13": {"\ue01f"},
"ans14": {"\ue01f"},
"ans15": {"\ue01f"},
"ans16": {"\ue01f"},
"ans17": {"\ue01f"},
"ans18": {"\ue01f"},
"ans19": {"\ue01b"},
"ans20": {"\ue01b"},
"ans21": {"\ue01b"},
"ans22": {"\ue01b"}
}
},
{"sec4":
{
"ans1": {"\ue01b"},
"ans2": {"\ue01b"},
"ans3": {"\ue01b"},
"ans4": {"\ue01b"},
"ans5": {"\ue01b"},
"ans6": {"\ue01b"},
"ans7": {"\ue01b"},
"ans8": {"\ue01b"},
"ans9": {"\ue01f"},
"ans10": {"\ue01f"},
"ans11": {"\ue01f"},
"ans12": {"\ue01f"},
"ans13": {"\ue01f"},
"ans14": {"\ue01f"},
"ans15": {"\ue01f"},
"ans16": {"\ue01f"},
"ans17": {"\ue01b"},
"ans18": {"\ue01b"},
"ans19": {"\ue01b"},
"ans20": {"\ue01b"}
}
}
}
{"acuity2":
{"sec1":
{
"ans1": {"\ue01d"},
"ans2":{"\ue01d"},
"ans3": {"\ue01d"},
"ans4": {"\ue01d"},
"ans5": {"\ue01d"},
"ans6": {"\ue01d"},
"ans7": {"\ue01d"},
"ans8": {"\ue01d"},
"ans9": {"\ue01d"},
"ans10": {"\ue01d"},
"ans11": {"\ue01d"},
"ans12": {"\ue01d"},
"ans13": {"\ue01d"},
"ans14": {"\ue01d"},
"ans15": {"\ue01d"},
"ans16": {"\ue01d"},
"ans17": {"\ue01d"},
"ans18": {"\ue01d"},
"ans19": {"\ue01d"},
"ans20": {"\ue01d"},
"ans21": {"\ue01d"},
"ans22": {"\ue01d"},
"ans23": {"\ue01d"},
"ans24": {"\ue01d"},
"ans25": {"\ue01d"},
"ans26": {"\ue01d"},
"ans27": {"\ue01d"},
"ans28": {"\ue01d"},
"ans29": {"\ue01d"},
"ans30": {"\ue01d"},
"ans31": {"\ue01d"},
"ans32": {"\ue01d"},
"ans33": {"\ue01d"},
"ans34": {"\ue01d"},
"ans35": {"\ue01d"}
},
{"sec2":
{
"ans1":1 {"\ue01d"},
"ans2": {"\ue01d"},
"ans3": {"\ue01d"},
"ans4": {"\ue01d"},
"ans5": {"\ue01d"},
"ans6": {"\ue01d"},
"ans7": {"\ue01d"},
"ans8": {"\ue01d"},
"ans9": {"\ue01d"},
"ans10": {"\ue01d"},
"ans11": {"\ue01d"},
"ans12": {"\ue01d"},
"ans13": {"\ue01d"},
"ans14": {"\ue01d"},
"ans15": {"\ue01d"},
"ans16": {"\ue01d"}
}
},
{"sec3":
{
"ans1": {"\ue01d"},
"ans2": {"\ue01d"},
"ans3": {"\ue01d"},
"ans4": {"\ue01d"},
"ans5": {"\ue01d"},
"ans6": {"\ue01d"},
"ans7": {"\ue01d"},
"ans8": {"\ue01d"},
"ans9": {"\ue01d"},
"ans10": {"\ue01d"},
"ans11": {"\ue01d"},
"ans12": {"\ue01d"},
"ans13": {"\ue01d"},
"ans14": {"\ue01d"},
"ans15": {"\ue01d"},
"ans16": {"\ue01d"},
"ans17": {"\ue01d"},
"ans18": {"\ue01d"},
"ans19": {"\ue01d"},
"ans20": {"\ue01d"},
"ans21": {"\ue01d"},
"ans22": {"\ue01d"}
}
},
{"sec4":
{
"ans1": {"\ue01d"},
"ans2": {"\ue01d"},
"ans3": {"\ue01d"},
"ans4": {"\ue01d"},
"ans5": {"\ue01d"},
"ans6": {"\ue01d"},
"ans7": {"\ue01d"},
"ans8": {"\ue01d"},
"ans9": {"\ue01d"},
"ans10": {"\ue01d"},
"ans11": {"\ue01d"},
"ans12": {"\ue01d"},
"ans13": {"\ue01d"},
"ans14": {"\ue01d"},
"ans15": {"\ue01d"},
"ans16": {"\ue01d"},
"ans17": {"\ue01d"},
"ans18": {"\ue01d"},
"ans19": {"\ue01d"},
"ans20": {"\ue01d"}
}
}
},
{"acuity3":
{"sec1":
{
"ans1": {"\ue01f"},
"ans2":{"\ue01f"},
"ans3": {"\ue01f"},
"ans4": {"\ue01f"},
"ans5": {"\ue01f"},
"ans6": {"\ue01f"},
"ans7": {"\ue01f"},
"ans8": {"\ue01f"},
"ans9": {"\ue01f"},
"ans10": {"\ue01f"},
"ans11": {"\ue01f"},
"ans12": {"\ue01f"},
"ans13": {"\ue01f"},
"ans14": {"\ue01f"},
"ans15": {"\ue01f"},
"ans16": {"\ue01b"},
"ans17": {"\ue01b"},
"ans18": {"\ue01b"},
"ans19": {"\ue01b"},
"ans20": {"\ue01b"},
"ans21": {"\ue01b"},
"ans22": {"\ue01b"},
"ans23": {"\ue01b"},
"ans24": {"\ue01b"},
"ans25": {"\ue01b"},
"ans26": {"\ue01b"},
"ans27": {"\ue01b"},
"ans28": {"\ue01b"},
"ans29": {"\ue01b"},
"ans30": {"\ue01b"},
"ans31": {"\ue01b"},
"ans32": {"\ue01b"},
"ans33": {"\ue01b"},
"ans34": {"\ue01b"},
"ans35": {"\ue01b"}
},
},
{"sec2":
{
"ans1":1 {"\ue01f"},
"ans2": {"\ue01f"},
"ans3": {"\ue01f"},
"ans4": {"\ue01f"},
"ans5": {"\ue01f"},
"ans6": {"\ue01f"},
"ans7": {"\ue01f"},
"ans8": {"\ue01f"},
"ans9": {"\ue01b"},
"ans10": {"\ue01b"},
"ans11": {"\ue01b"},
"ans12": {"\ue01b"},
"ans13": {"\ue01b"},
"ans14": {"\ue01b"},
"ans15": {"\ue01b"},
"ans16": {"\ue01b"}
},
},
{"sec3":
{
"ans1": {"\ue01f"},
"ans2": {"\ue01f"},
"ans3": {"\ue01f"},
"ans4": {"\ue01f"},
"ans5": {"\ue01f"},
"ans6": {"\ue01f"},
"ans7": {"\ue01f"},
"ans8": {"\ue01f"},
"ans9": {"\ue01f"},
"ans10": {"\ue01f"},
"ans11": {"\ue01b"},
"ans12": {"\ue01b"},
"ans13": {"\ue01b"},
"ans14": {"\ue01b"},
"ans15": {"\ue01b"},
"ans16": {"\ue01b"},
"ans17": {"\ue01b"},
"ans18": {"\ue01b"},
"ans19": {"\ue01f"},
"ans20": {"\ue01f"},
"ans21": {"\ue01f"},
"ans22": {"\ue01f"}
},
},
{"sec4":
{
"ans1": {"\ue01f"},
"ans2": {"\ue01f"},
"ans3": {"\ue01f"},
"ans4": {"\ue01f"},
"ans5": {"\ue01f"},
"ans6": {"\ue01f"},
"ans7": {"\ue01f"},
"ans8": {"\ue01f"},
"ans9": {"\ue01b"},
"ans10": {"\ue01b"},
"ans11": {"\ue01b"},
"ans12": {"\ue01b"},
"ans13": {"\ue01b"},
"ans14": {"\ue01b"},
"ans15": {"\ue01b"},
"ans16": {"\ue01b"},
"ans17": {"\ue01f"},
"ans18": {"\ue01f"},
"ans19": {"\ue01f"},
"ans20": {"\ue01f"}
}
}
}
CodePudding user response:
Remove the curly braces from the dictionaries without keys. The encoded values, are inside dictionaries. They should be values for the ans
keys.
Also, you have an error at ans1 (repeated in another dictionary), 1 after column:
{"sec2":
{
"ans1":1 {"\ue01d"},
(...)
CodePudding user response:
Turned out i needed to add some endings and rearrange it a bit. Final solution:
{"acuity1":[
{"sec1":[{
"ans1": "\ue01b",
"ans2":"\ue01b",
"ans3": "\ue01b",
"ans4": "\ue01b",
"ans5": "\ue01b",
"ans6": "\ue01b",
"ans7": "\ue01b",
"ans8": "\ue01b",
"ans9": "\ue01b",
"ans10": "\ue01b",
"ans11": "\ue01b",
"ans12": "\ue01b",
"ans13": "\ue01b",
"ans14": "\ue01b",
"ans15": "\ue01b",
"ans16": "\ue01f",
"ans17": "\ue01f",
"ans18": "\ue01f",
"ans19": "\ue01f",
"ans20": "\ue01f",
"ans21": "\ue01f",
"ans22": "\ue01f",
"ans23": "\ue01f",
"ans24": "\ue01f",
"ans25": "\ue01f",
"ans26": "\ue01f",
"ans27": "\ue01f",
"ans28": "\ue01f",
"ans29": "\ue01f",
"ans30": "\ue01f",
"ans31": "\ue01f",
"ans32": "\ue01f",
"ans33": "\ue01f",
"ans34": "\ue01f",
"ans35": "\ue01f"
}]},
{"sec2":[{
"ans1": "\ue01b",
"ans2": "\ue01b",
"ans3": "\ue01b",
"ans4": "\ue01b",
"ans5": "\ue01b",
"ans6": "\ue01b",
"ans7": "\ue01b",
"ans8": "\ue01b",
"ans9": "\ue01f",
"ans10": "\ue01f",
"ans11": "\ue01f",
"ans12": "\ue01f",
"ans13": "\ue01f",
"ans14": "\ue01f",
"ans15": "\ue01f",
"ans16": "\ue01f"
}]},
{"sec3":[{
"ans1": "\ue01b",
"ans2": "\ue01b",
"ans3": "\ue01b",
"ans4": "\ue01b",
"ans5": "\ue01b",
"ans6": "\ue01b",
"ans7": "\ue01b",
"ans8": "\ue01b",
"ans9": "\ue01b",
"ans10": "\ue01b",
"ans11": "\ue01f",
"ans12": "\ue01f",
"ans13": "\ue01f",
"ans14": "\ue01f",
"ans15": "\ue01f",
"ans16": "\ue01f",
"ans17": "\ue01f",
"ans18": "\ue01f",
"ans19": "\ue01b",
"ans20": "\ue01b",
"ans21": "\ue01b",
"ans22": "\ue01b"
}]},
{"sec4":[{
"ans1": "\ue01b",
"ans2": "\ue01b",
"ans3": "\ue01b",
"ans4": "\ue01b",
"ans5": "\ue01b",
"ans6": "\ue01b",
"ans7": "\ue01b",
"ans8": "\ue01b",
"ans9": "\ue01f",
"ans10": "\ue01f",
"ans11": "\ue01f",
"ans12": "\ue01f",
"ans13": "\ue01f",
"ans14": "\ue01f",
"ans15": "\ue01f",
"ans16": "\ue01f",
"ans17": "\ue01b",
"ans18": "\ue01b",
"ans19": "\ue01b",
"ans20": "\ue01b"
}]} ,
{"acuity2":[
{"sec1":[{
"ans1": "\ue01d",
"ans2":"\ue01d",
"ans3": "\ue01d",
"ans4": "\ue01d",
"ans5": "\ue01d",
"ans6": "\ue01d",
"ans7": "\ue01d",
"ans8": "\ue01d",
"ans9": "\ue01d",
"ans10": "\ue01d",
"ans11": "\ue01d",
"ans12": "\ue01d",
"ans13": "\ue01d",
"ans14": "\ue01d",
"ans15": "\ue01d",
"ans16": "\ue01d",
"ans17": "\ue01d",
"ans18": "\ue01d",
"ans19": "\ue01d",
"ans20": "\ue01d",
"ans21": "\ue01d",
"ans22": "\ue01d",
"ans23": "\ue01d",
"ans24": "\ue01d",
"ans25": "\ue01d",
"ans26": "\ue01d",
"ans27": "\ue01d",
"ans28": "\ue01d",
"ans29": "\ue01d",
"ans30": "\ue01d",
"ans31": "\ue01d",
"ans32": "\ue01d",
"ans33": "\ue01d",
"ans34": "\ue01d",
"ans35": "\ue01d"
}]},
{"sec2":[{
"ans1": "\ue01d",
"ans2": "\ue01d",
"ans3": "\ue01d",
"ans4": "\ue01d",
"ans5": "\ue01d",
"ans6": "\ue01d",
"ans7": "\ue01d",
"ans8": "\ue01d",
"ans9": "\ue01d",
"ans10": "\ue01d",
"ans11": "\ue01d",
"ans12": "\ue01d",
"ans13": "\ue01d",
"ans14": "\ue01d",
"ans15": "\ue01d",
"ans16": "\ue01d"
}]},
{"sec3":[{
"ans1": "\ue01d",
"ans2": "\ue01d",
"ans3": "\ue01d",
"ans4": "\ue01d",
"ans5": "\ue01d",
"ans6": "\ue01d",
"ans7": "\ue01d",
"ans8": "\ue01d",
"ans9": "\ue01d",
"ans10": "\ue01d",
"ans11": "\ue01d",
"ans12": "\ue01d",
"ans13": "\ue01d",
"ans14": "\ue01d",
"ans15": "\ue01d",
"ans16": "\ue01d",
"ans17": "\ue01d",
"ans18": "\ue01d",
"ans19": "\ue01d",
"ans20": "\ue01d",
"ans21": "\ue01d",
"ans22": "\ue01d"
}]},
{"sec4":[{
"ans1": "\ue01d",
"ans2": "\ue01d",
"ans3": "\ue01d",
"ans4": "\ue01d",
"ans5": "\ue01d",
"ans6": "\ue01d",
"ans7": "\ue01d",
"ans8": "\ue01d",
"ans9": "\ue01d",
"ans10": "\ue01d",
"ans11": "\ue01d",
"ans12": "\ue01d",
"ans13": "\ue01d",
"ans14": "\ue01d",
"ans15": "\ue01d",
"ans16": "\ue01d",
"ans17": "\ue01d",
"ans18": "\ue01d",
"ans19": "\ue01d",
"ans20": "\ue01d"
}]},
{"acuity3":[
{"sec1":[{
"ans1": "\ue01f",
"ans2":"\ue01f",
"ans3": "\ue01f",
"ans4": "\ue01f",
"ans5": "\ue01f",
"ans6": "\ue01f",
"ans7": "\ue01f",
"ans8": "\ue01f",
"ans9": "\ue01f",
"ans10": "\ue01f",
"ans11": "\ue01f",
"ans12": "\ue01f",
"ans13": "\ue01f",
"ans14": "\ue01f",
"ans15": "\ue01f",
"ans16": "\ue01b",
"ans17": "\ue01b",
"ans18": "\ue01b",
"ans19": "\ue01b",
"ans20": "\ue01b",
"ans21": "\ue01b",
"ans22": "\ue01b",
"ans23": "\ue01b",
"ans24": "\ue01b",
"ans25": "\ue01b",
"ans26": "\ue01b",
"ans27": "\ue01b",
"ans28": "\ue01b",
"ans29": "\ue01b",
"ans30": "\ue01b",
"ans31": "\ue01b",
"ans32": "\ue01b",
"ans33": "\ue01b",
"ans34": "\ue01b",
"ans35": "\ue01b"
}]},
{"sec2":[{
"ans1": "\ue01f",
"ans2": "\ue01f",
"ans3": "\ue01f",
"ans4": "\ue01f",
"ans5": "\ue01f",
"ans6": "\ue01f",
"ans7": "\ue01f",
"ans8": "\ue01f",
"ans9": "\ue01b",
"ans10": "\ue01b",
"ans11": "\ue01b",
"ans12": "\ue01b",
"ans13": "\ue01b",
"ans14": "\ue01b",
"ans15": "\ue01b",
"ans16": "\ue01b"
}]},
{"sec3":[{
"ans1": "\ue01f",
"ans2": "\ue01f",
"ans3": "\ue01f",
"ans4": "\ue01f",
"ans5": "\ue01f",
"ans6": "\ue01f",
"ans7": "\ue01f",
"ans8": "\ue01f",
"ans9": "\ue01f",
"ans10": "\ue01f",
"ans11": "\ue01b",
"ans12": "\ue01b",
"ans13": "\ue01b",
"ans14": "\ue01b",
"ans15": "\ue01b",
"ans16": "\ue01b",
"ans17": "\ue01b",
"ans18": "\ue01b",
"ans19": "\ue01f",
"ans20": "\ue01f",
"ans21": "\ue01f",
"ans22": "\ue01f"
}]},
{"sec4":[{
"ans1": "\ue01f",
"ans2": "\ue01f",
"ans3": "\ue01f",
"ans4": "\ue01f",
"ans5": "\ue01f",
"ans6": "\ue01f",
"ans7": "\ue01f",
"ans8": "\ue01f",
"ans9": "\ue01b",
"ans10": "\ue01b",
"ans11": "\ue01b",
"ans12": "\ue01b",
"ans13": "\ue01b",
"ans14": "\ue01b",
"ans15": "\ue01b",
"ans16": "\ue01b",
"ans17": "\ue01f",
"ans18": "\ue01f",
"ans19": "\ue01f",
"ans20": "\ue01f"
}]}]
}]}]}