#include <bits/stdc++.h> using namespace std; int main(){ string a; int s=0; cin>>a; while(a.find("luogu")!=string::npos){ s++; } cout<<s; }