I have the JSON response below and I want to count the occurrence of string matches in the "ref_id" objects. But I have no idea where to start when looping through the array and counting the matches. Any help or recommendation where I should start would be appreciated
{
"tag": "checkthisServer",
"success": 1,
"error": 0,
"svd_ids": [
{
"ref_id": "f91e2651"
},
{
"ref_id": "f91e2651"
},
{
"ref_id": "ue87sr5d"
},
{
"ref_id": "f91e2651"
}
{
"ref_id": "ue87sr5d"
}
]
}
Output should be:
f91e2651: 3
ue87sr5d: 2