#include int main() { int i; char S[128]; scanf( "%s", S ); for( i = 0; S[i] != '\0'; i++ ) if( S[i] == '5' ) if( S[i+1] == '7' ) if( S[i+2] == '5' ) { printf( "YES" ); return 0; } printf( "NO" ); return 0; }