Command exited with non-zero status 124

  Kiến thức lập trình
#include <bits/stdc++.h>
using namespace std;

int main() {
size_t t,n,m,k;cin>>t;
string a;
while(t--){
    cin>>n>>m>>k>>a;
    if(m>n){ cout<<"YESn";
        continue;}
    for(size_t i=0;i<n;){
                    if(i=a.find("L",i))!=string::npos){
           if(m+k>=a.find("L",i)){
            if(n-i<=m+k) {cout<<"YESn";
            break;}
           }
           else{
            cout<<"NOn";
            break;}
    }}
}
return 0;
}

so basically i have to cross a river of length n , with C (crocodiles) ,L(logs) in it
but upon running it with the input
6 2 0
LWLLLW
6 1 1
LWLLLL
6 1 1
LWLLWL
6 2 15
LWLLCC
6 10 0
CCCCCC
6 6 1
WCCCCW

i am getting the error mentioned in the title.

tell me what is triggering that error

New contributor

Aditya Raj is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.

Theme wordpress giá rẻ Theme wordpress giá rẻ Thiết kế website

LEAVE A COMMENT