与7无关的数
You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.
【题目描述】
一个正整数,如果它能被7整除,或者它的十进制表示法中某一位上的数字为7,则称其为与7相关的数。现求所有小于等于n(n<100)与7无关的正整数的平方和。
【输入】
输入为一行,正整数n(n < 100)。
【输出】
输出一行,包含一个整数,即小于等于n的所有与7无关的正整数的平方和。
【输入样例】
21
【输出样例】
2336
2025年入门组测试四(2025.3.16)
- Status
- Done
- Rule
- IOI
- Problem
- 7
- Start at
- 2025-3-16 7:30
- End at
- 2025-3-16 19:30
- Duration
- 12 hour(s)
- Host
- Partic.
- 10