
#include<iostream>
#include<string>
#include<stack>
using namespace std;
int main()
{
string str;
cin >> str;
stack<char> s;
for (auto a : str)
{
if (a == '[' || a == '(')
{
s.push(a);
}
if (a == ']' )
{
if (s.size() == 0)
{
cout << "false";
return 0;
}
else
{
auto x=s.top();
if (x == '[')
{
s.pop();
}
else
{
cout << "false";
return 0;
}
}
}
if (a == ')')
{
if (s.size() == 0)
{
cout << "false";
return 0;
}
else
{
auto x = s.top();
if (x == '(')
{
s.pop();
}
else
{
cout << "false";
return 0;
}
}
}
}
if (s.size() == 0)
{
cout << "true";
}
else {
cout << "false";
}
system("pause");
}

#include<iostream>
#include<cmath>
using namespace std;
int main()
{
int n;
cin >> n;
while (n--)
{
int x;
cin >> x;
int i = 1;
int c = 0;
for (; i < sqrt(x); i++)
{
if (x%i == 0) {
c+=2;
}
}
i = sqrt(x);
if(i*i == x)
{
c++;
}
cout << c << endl;
}
system("pause");
}

#include <iostream>
#include <cmath>
using namespace std;
int main() {
long N = 100;
while (cin >> N)
{
long count = 0;
for (long j = 2; j <= sqrt(N); j++)
{
while (N%j == 0)
{
N = N / j;
count++;
}
if (N == 1)
break;
}
if (N>1)
count++;
cout << count << endl;
}
return 0;
}