get_string(String) :- current_input(Input),
     read_string(Input, ' \n', '', _, String).
     
solve([]) :- write("No").
solve(['7'|A]) :- write("Yes").
solve([_|A]) :- solve(A).

main :- get_string(Str),srting_chars(Str,List),