#include <iostream>
using namespace std;
int main()
{
string str;
getline(cin, str);
char s[100];
int a = 0;
if(str[str.length() - 1] == 'g' && str[str.length() - 2] == 'n' && str[str.length() - 3] == 'i')
{
for(int i = 0; i < str.length() - 3; i++)
{
s[i] = str[i];
}
a += 1;
}
if(str[str.length() - 1] == 'r' && str[str.length() - 2] == 'e' )
{
for(int i = 0; i < str.length() - 2; i++)
{
s[i] = str[i];
}
a += 1;
}
if(str[str.length() - 1] == 'y' && str[str.length() - 2] == 'l' )
{
for(int i = 0; i < str.length() - 2; i++)
{
s[i] = str[i];
}
a += 1;
}
if( a == 0)
{
for(int i = 0; i <= str.length() - 1; i ++)
{
s[i] = str[i];
}
}
cout << s << endl;
return 0;
}