#include using namespace std; int main() { string s; cin>>s; int L=0, R=0; char p=0; for(auto& c: s) { if (c=='*') { (p=='^'?L:R)++; } p=c; } cout<