Universal Cup Judging System

Universal Cup

Limite de temps : 2.0 s Limite de mémoire : 1024 MB Points totaux : 100 Hackable ✓
Statistiques

נתון לך מספר שלם $N$ המיוצג בבסיס עשרוני.

נתבונן בכל המספרים השלמים שניתן ליצור על ידי סידור מחדש של הספרות של $N$ כך שלמספר המתקבל אין אפסים מובילים.

מצא את מספרם של מספרים שלמים כאלה המתחלקים ב-$11$, מודולו $2147483647$ ($= 2^{31} - 1$), שהוא מספר ראשוני.

שים לב שהמספרים השלמים הנוצרים על ידי סידור מחדש של הספרות של $N$ כוללים את $N$ עצמו.

קלט

הקלט ניתן בפורמט הבא:

$$N$$

  • כל ערכי הקלט הם מספרים שלמים.
  • $1 \le N < 10^{2 \times 10^6}$
  • $N$ ניתן בבסיס עשרוני ללא אפסים מובילים.

פלט

הדפס את התשובה בשורה בודדת.

דוגמאות

קלט 1

1001

פלט 1

2

קלט 2

31415926535

פלט 2

144000

הערה

בדוגמה הראשונה, $1100$ ו-$1001$ מקיימים את התנאי.

Editorials

IDTypeStatusTitlePosted ByLast UpdatedActions
#1408EditorialOpen题解jianglyView

Discussions

About Discussions

The discussion section is only for posting: General Discussions (problem-solving strategies, alternative approaches), and Off-topic conversations.

This is NOT for reporting issues! If you want to report bugs or errors, please use the Issues section below.

Open Discussions 0
No discussions in this category.

Issues

About Issues

If you find any issues with the problem (statement, scoring, time/memory limits, test cases, etc.), you may submit an issue here. A problem moderator will review your issue.

Guidelines:

  1. This is not a place to publish discussions, editorials, or requests to debug your code. Issues are only visible to you and problem moderators.
  2. Do not submit duplicated issues.
  3. Issues must be filed in English or Chinese only.
Active Issues 0
No issues in this category.
Closed/Resolved Issues 0
No issues in this category.