DivisibilityTime Limit...
转载 2019-04-16 14:25:00
57阅读
2评论
把当前数删除几位然后能够整除与8 那么可得知大于3位数的推断能否整除于八的条件是(n%1000)%8==0 能够得出我们的结论:仅仅须要枚举后三位后两位后一位就可以知道是否可整除于8 #include <cstdio> #include <cstring> #include <algorithm>
转载 2017-08-11 08:45:00
42阅读
DivisibilityTime Limit...
转载 2019-04-16 14:25:00
36阅读
2评论
#include <iostream> //dpusing namespace std;long long in[10005],dp[10005][105]; //dp[i][j]表示前i个数的组合 mod k =j 的可能数int main(){ int n,k; cin>>n>>k; for(int i=1;i<=n;++i) { scanf("%lld",&in[i]); //如果scanf("%d",&in[i]); 会WA in[i]%=k; } dp[1][(in[1]+k)%k]=1
转载 2011-07-22 19:10:00
67阅读
2评论
Problem DescriptionAs we know,the fzu AekdyCoin is famous of math,especially in the field of number theory.So,many people call him "the descendant of Chen Jingrun",which brings him a good reputati
原创 2022-11-09 21:53:21
53阅读
Divisibility Time Limit: 1000MS   Memory Limit: 10000K Total Submissions: 10485   Accepted: 3738 Description Consider an arbitrary sequence of integers. One can place + or
原创 2023-04-24 08:38:10
70阅读
Consider an arbitrary sequence of integers. One can place + or - operators between integers in the sequence, thus deriving different arithmetical expr
转载 2017-09-27 21:06:00
210阅读
If an integer is not divisible by 2 or 5, some multiple of that number in decimal
原创 2022-10-18 16:35:10
83阅读
这一题的题意是 如输入 3 1 则要求输出最...
转载 2015-12-26 21:57:00
67阅读
2评论
题意: 给你一个10进制的b和x,对于任意的一个b进制的y。如果y每一位的和可以被x整除,且y可以被x整除;或者如果y每一位的和不可以被x整除,且y不可以被x整除。那么就输出T。否则输出F 题解: 代码: #include<stack> #include<queue> #include<map> #
转载 2020-08-08 08:41:00
40阅读
2评论
J. Divisibility time limit per test 0.5 seconds memory limit per test 64 megabytes input standard input output standard output IT City company develop
转载 2016-02-19 20:30:00
438阅读
2评论
Description
原创 2023-02-04 08:55:42
62阅读
F. Divisibility time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output F. Divisibility time limi
原创 2021-12-27 16:51:12
63阅读
time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output You are given a non-negative integ...
原创 2022-03-13 14:28:38
72阅读
CodeForces - 597ADivisibilityTime Limit: 1000MS Memory Limit: 262144KB 64bit IO Format: %I64d & %I64uSubmit StatusDescriptionFin、
原创 2023-05-08 21:23:39
133阅读
题意:能否在一个整数序列的每相邻的两项之间添加一个加减号,使得最终结果能被一个给定整数K 2 #include 3 #include 4 #define maxn 20000 5 using namespace std; 6 7 int t; 8 int n,k; 9 int a[maxn];...
转载 2014-10-13 19:50:00
174阅读
2评论
DivisibilityTime Limit: 1000MSMemory Limit: 10000KTotal Submissions: 10598Accepted: 3787DescriptionConsider an arbitrary sequence of integers. One can...
转载 2015-08-22 11:13:00
97阅读
2评论
http://codeforces.com/problemset/problem/550/Ctime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputYou are given a non-negative integ...
原创 2021-09-06 14:31:22
29阅读
糟烂的代码啊...  这个题目思路很简单——末位只可能为0和5,所有数字的和肯定被3整除 没有0和5的肯定不行 否则,把所有数字求和 如果被3整除,则从大到小输出 如果除3余1,则按以下顺序——删1;删4;删7;删2、5、8中的2个(特别注意如果没有0要保留一个5) 如果除3余2,则按以下顺序——删2;删5(特别注意如果没有0要保留);删8;删1、4、7中的2个   下面是糟烂的代码——   /
转载 2013-07-29 19:27:00
55阅读
2评论
mit per test256 megabytesinputstandard inputoutputstandard outputYou are given a non-
原创 2022-09-07 16:42:43
80阅读
  • 1
  • 2
  • 3
  • 4