How to count selected only data

I have a response :

  [
    [
        "Andi",
        "PENDING"
    ],
    [
        "John",
        "PENDING"
    ],
    [
        "Lisa",
        "ACTIVE"
    ],
    [
        "Indri",
        "ACTIVE"
    ]
]

How to count length only for ACTIVE response data?

Hey @FaizPrakoso

Welcome to the community! :rocket:

This is a hacky and probably not the most efficient way of doing it but It should count them:

counter = 0
_.each(pm.response.json(), (item) => {
    if(item.includes('ACTIVE')) {
        counter = counter + 1
    }
})

console.log(counter)