首页
DreamJudge
院校信息
考研初试
机试真题
兑换中心
登录
注册
上岸
以下题解仅供学习参考使用。
抄袭、复制题解,以达到刷AC率/AC数量或其他目的的行为,在N诺是严格禁止的。
N诺非常重视学术诚信。此类行为将会导致您成为作弊者。具体细则请查看N诺社区规则。
西电机试专家
2025年3月26日 17:31
2048的游戏 题解:优先队列so easy
P1208
回复 0
|
赞 4
|
浏览 394
#include<bits/stdc++.h> using namespace std; int main(){ int n; cin>>n; while(n--){ int cnt; cin>>cnt; &...
dhh390
2025年3月23日 18:25
2048的游戏 题解:超简单的c语言
P1208
回复 1
|
赞 5
|
浏览 403
#include <stdio.h> #include <string.h> #include<stdlib.h> #include<math.h> #include<time.h> int main() { int t; scanf("%d",&t); int i; for(i=0;i<t;i++)  ...
无123456
2025年3月22日 15:15
2048的游戏 题解:这是我在b站上学到动态规划后感觉可以一试
P1208
回复 0
|
赞 6
|
浏览 383
#include<bits/stdc++.h> using namespace std; int main(){ int t=0; cin>>t; int k=0; for(k=0;k<t;k++){ int n=0; cin>>n; vector<int>a(n); vector<int>dp(2049,0); int l=0,r=0,sum=0,flag=0; for(int j=0;j<n;j++){ cin>>a[j]; ...
无123456
2025年3月20日 16:07
2048的游戏 题解:
P1208
回复 3
|
赞 5
|
浏览 388
采用滑动窗口做,不知道为什么如果没有在输入时判断输入数据是否等于2048就只会对50%,有没有大佬能解释一下 #include<bits/stdc++.h> using namespace std; int main(){ int t=0; cin>>t; int i=0; for(i=0;i<t;i++){ int n=0; cin>>n; vector<int>a(n); int l=0,r=0,sum=0,flag=0; for(int j=0;j<n;j++){ ...
csYfZhang
2020年5月20日 12:24
尺取法打卡
P1208
回复 0
|
赞 8
|
浏览 7.0k
#include<iostream> #include<cstdio> #include<string> #include<string.h> #include<algorithm> #include<vector> #include<map> #include<queue> using namespace std; #define ll int #define inf 0x3f3f3f3f #define MAXN 20005 #define vec vect...
题目
2048的游戏
题解数量
5
发布题解
在线答疑
热门题解
1
尺取法打卡
2
2048的游戏 题解:这是我在b站上学到动态规划后感觉可以一试
3
2048的游戏 题解:超简单的c语言
4
2048的游戏 题解:
5
2048的游戏 题解:优先队列so easy