Power digit sumProblem 16215 = 32768 and the sum of its digits is 3 + 2 + 7 + 6 + 8 = 26.What is the sum of the digits of the number 2...
转载 2017-03-22 19:28:00
42阅读
2评论
Power digit sumProblem 16215 = 32768 and the sum of its digits is 3 + 2 + 7 + 6 + 8 = 26.What is the sum of the digits of the number 2...
转载 2017-03-22 19:28:00
24阅读
2评论
Problem 16 215 = 32768 and the sum of its digits is 3 + 2 + 7 + 6 + 8 = 26. What is the sum of the digits of the number 21000? Answer: 1366
原创 2022-08-11 15:01:29
53阅读
【题意】我们要找出最小的正整数n满足——a*S(n)==b*S(2n)a,b的范围都在[1,100]【分析&推导】首先可以有这样的基础性结论:设gcd(a,b)=g, 我们可以先使得b=b/g, a=a/gS(n):S(2n)==b:a,那么我们有S(n):S(2n)=b:a。然后,一个好的做法是,我们研究本质问题。我们发现,如果一个digit是0~4,
原创 2022-04-20 10:25:24
30阅读
#include<cstring> using namespace std; int ans[100]; int tot; int gcd(int n,i
原创 2022-11-09 18:30:49
43阅读
题目链接:HDU 7105 Power Sum 题目大意: 题解: 易知$(x+1)^2-(x+2)^2-(x+3)^2+(x+4)^2=4$,所以可以令$n$对$4$取模,根据余数$0,1,2,3$取不同的$01$序列,后面加上$\frac{n}{4}$个“\(1001\)”即可。 #includ ...
转载 2021-08-29 18:23:00
139阅读
2评论
给出 $n\ (1\leq n\leq 10^6)$ ,求长度为 $K\ (1\leq K\leq n+2)$ 的数列 $\{a_i\}\ (a_i\in {-1, 1})$ 使得 $\sum_{i=1}^Ka_i\times i^2=n$ ...
转载 2021-10-14 11:46:00
67阅读
2评论
Factorial digit sumProblem 20n! means n × (n − 1) × ... × 3 × 2 × 1For example, 10! = 10 × 9 × ... × 3 × 2 × 1 = 3628800,and the sum o...
转载 2017-03-23 00:11:00
183阅读
2评论
Digit SumDescriptionThe security system forAssociated Computer Informatics Systems(ACIS) has an interesting test to check the identity for authorized personal. These persons have got a piece of software that allowed them to calculate, given two integer positive numbersMandN, what is the sum of the d
转载 2012-10-28 11:09:00
134阅读
2评论
测试地址:Digit-Sum题目大意: 令S(n)S(n)S(n)为nnn的十进制表示的各个数位之和,要求构造出一个最小正整数满足a⋅S(n)=b⋅S(2n)a\cdot S(n)=b\cdot S(2n)a⋅S(n)=b⋅S(2n)。做法: 本题需要用到思...
转载 2018-09-20 22:27:00
58阅读
2评论
Probl
原创 2022-08-11 15:03:14
237阅读
A - Digit Sum 2Time limit : 2sec / Memory limit : 256MBScore : 300 pointsProblem StatementFind the maximum
原创 2022-11-22 20:09:09
61阅读
题目链接:https://atcoder.jp/contests/abc336/tasks/abc336_e题目大意:我们定义一个整数 \(n\) 的 数位和 为 \(n\) 的十进制表示中的各位上的数字之和。比如:整数 \(2024\) 的数位和为 \(2 + 0 + 2 + 4 = 8\)。一个正整数 \(n\) 被称作一个 好数 如果 \(n\) 能被它的数位和整除。举例,\(2024\)
原创 2024-01-22 13:56:16
132阅读
1. power(x1, x2)    对x1中的每个元素求x2次方。不会改变x1上午shape。2. sum(a, axis=None, dtype=None, out=None, keepdims=False) 对a求和,如果axis=None,将矩阵中的每一个数加起来,如果axis=0,矩阵按列相加,如果axis大于0,矩
转载 2023-03-20 09:36:33
180阅读
cstdio>#include<cstring>#include<iostream>#include&lt...
原创 2023-02-03 10:40:44
39阅读
数据源: 任意数据源,一列数值,一列非数值(文本) 目标: 对数值列进行求和等计算,对非数值列进行计数等计算 操作过程: 选取待计算的列》【转换】》【统计信息】》选取 M公式: 求和:= List.Sum( 数值列表, 精度) 精度: Precision.Double / 0 / 缺省:双精度 Pr
原创 2022-09-20 06:40:29
249阅读
Problem DescriptionGiven a positive integer N, you shouldoutput the leftmost digit of N^N. InputThe input contains several test cases.The first lin...
转载 2016-05-16 10:32:00
76阅读
2评论
ac1068这题说的是给了一个区间计算这个区间内 数各个数字之和为S的最小数 其实这个题目首先可以求出[A,B]内所有数字之和为S的数的个数cnt,然后观察一下,不难发现,最小的那个数字肯定是在 cnt=1的时候对应的区间端点。由于具有严格的单调性,即随着区间长度的延长,满足条件的cnt肯定会越来越...
原创 2022-06-05 01:46:25
91阅读
#include<bits/stdc++.h>using namespace std;#define rep(i,l,r) for(int i=(l);i<=(r);i++)#define per(i,l,r) for(int i
原创 2022-08-16 14:37:51
21阅读
## 实现“digit python”步骤 为了帮助你实现“digit python”,我将详细描述整个过程,并给出每个步骤需要做的事情以及相应的代码。 ### 步骤一:理解需求 在开始编写代码之前,我们需要明确目标和需求。根据题目,我们需要实现一个“digit python”,也就是一个能够识别和操作数字的Python程序。 ### 步骤二:创建Python文件 首先,我们需要创建一个
原创 2024-01-20 03:30:27
63阅读
  • 1
  • 2
  • 3
  • 4
  • 5