29532023-02-05 20:08:45lazingergoBimmbamm (30)cpp17Compilation error
#include <iostream>
#include <algorithm>
#include <climits>
#include <string>
#include <cctype>
#include <cstdlib>
#include <iomanip>
#include <math.h>


using namespace std;

#define ull unsigned long long
#define ll long long

const int I_INF = INT_MAX;
const ll LL_INF = LLONG_MAX;
const ull ULL_INF = ULLONG_MAX;




void solve()
{
	int n;
	cin >> n;

	string s;
	int hiba=-1;
	for (int i = 1; i <= n; i++)
	{
		cin >> s;
		if (not (i % 3 == 0 && i % 5 !=0  s == "BIMM" || i % 5 == 0  && i % 3 != 0&& s == "BAMM" || i % 3 == 0 && i % 5 == 0 && s == "BUMM" || i % 3 != 0 && i % 5 != 0 && s == "SZAM"))
		{
			hiba = i;
			break;
		}
	}

	if (hiba == -1)
		cout << 0;
	else 
		cout << hiba;



}



int main()
{
	//freopen("input.txt", "r", stdin);
	//freopen("output.txt", "w", stdout);

	solve();
	return 0;
}

Compilation error
exit status 1
main.cpp: In function 'void solve()':
main.cpp:33:49: error: expected ')' before 's'
   33 |                 if (not (i % 3 == 0 && i % 5 !=0  s == "BIMM" || i % 5 == 0  && i % 3 != 0&& s == "BAMM" || i % 3 == 0 && i % 5 == 0 && s == "BUMM" || i % 3 != 0 && i % 5 != 0 && s == "SZAM"))
      |                         ~                       ^ ~
      |                                                 )
main.cpp:37:18: error: expected ')' before '}' token
   37 |                 }
      |                  ^
      |                  )
   38 |         }
      |         ~         
main.cpp:33:20: note: to match this '('
   33 |                 if (not (i % 3 == 0 && i % 5 !=0  s == "BIMM" || i % 5 == 0  && i % 3 != 0&& s == "BAMM" || i % 3 == 0 && i % 5 == 0 && s == "BUMM" || i % 3 != 0 && i % 5 != 0 && s == "SZAM"))
      |                    ^
main.cpp:38:9: error: expected primary-expression before '}' token
   38 |         }
      |         ^
Exited with error status 1