import std.stdio, std.algorithm, std.string, std.string, std.conv; void main(){ writeln(count(readln(), "575") ? "YES" : "NO"); }