hiho week 239 register

Ended

Participants:101

Verdict:Accepted
Score:100 / 100
Submitted:2019-01-27 20:59:15

Lang:G++

Edit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#include<iostream>
#include<string>
using namespace std;
string s1;
int main()
{
    long dr=0,t,qx=0;
    bool b;
    cin>>t;
    for(long x=1;x<=t;x++)
    {
        cin>>s1;
        b=true;
        dr=0;
        qx=0;
        for(long x=0;x<s1.length();x++)
        {
            if(s1[x]=='A')
                qx++;
            if(qx==2)
            {
                b=false;
                break;
            }
            if(s1[x]=='L')
                dr++;
            else
                dr=0;
            if(dr==3)
            {
                b=false;
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX