#C2586. Perfect Number Checker

    ID: 45918 Type: Default 1000ms 256MiB

Perfect Number Checker

Perfect Number Checker

This problem requires you to determine whether a given positive integer n is a perfect number as defined in this problem:

A number is considered perfect if and only if every one of its digits is either a 3 or a 7. In other words, if we denote the digits of n by \(d_1, d_2, \dots, d_k\), then n is perfect if and only if \[ \forall i \in \{1, 2, \dots, k\},\ d_i \in \{3, 7\}. \]

For example, the numbers 37, 7337, and 777 are perfect numbers, while numbers like 123, 372, or any number that contains a digit other than 3 or 7 are not perfect.

inputFormat

The input is provided via stdin and consists of a single line containing one positive integer n.

\(1 \leq n \leq 10^{18}\) (the upper bound is indicative for practical input sizes, though your solution should work for any integer that fits in the available data type).

outputFormat

Output to stdout a single line containing the string YES if the number is a perfect number (contains only the digits 3 and 7). Otherwise, output NO.

## sample
37
YES