{"raw_statement":[{"iden":"problem statement","content":"Takahashi loves the number $7$ and multiples of $K$.\nWhere is the first occurrence of a multiple of $K$ in the sequence $7,77,777,\\ldots$? (Also see Output and Sample Input/Output below.)\nIf the sequence contains no multiples of $K$, print `-1` instead."},{"iden":"constraints","content":"*   $1 \\leq K \\leq 10^6$\n*   $K$ is an integer."},{"iden":"input","content":"Input is given from Standard Input in the following format:\n\n$K$"},{"iden":"sample input 1","content":"101"},{"iden":"sample output 1","content":"4\n\nNone of $7$, $77$, and $777$ is a multiple of $101$, but $7777$ is."},{"iden":"sample input 2","content":"2"},{"iden":"sample output 2","content":"\\-1\n\nAll elements in the sequence are odd numbers; there are no multiples of $2$."},{"iden":"sample input 3","content":"999983"},{"iden":"sample output 3","content":"999982"}],"translated_statement":null,"sample_group":[],"show_order":["default"],"formal_statement":null,"simple_statement":null,"has_page_source":true}