这名用户暂未设置签名。
追踪最近的用户名外显变动记录。
最近的文章、讨论、云剪贴板与社区记录
能过样例和第六个点 ```c++ #include #include #include #define inf 0x3f3f3f3f #define INF 0x7fffffff using namespace std; const int maxn = 1e6; struct node { int v, next,…
```c++ #include #include #include #define inf 0x3f3f3f3f #define INF 0x7fffffff using namespace std; const int maxn = 2e5; struct node { int v, next, w; }edge[m…
1)对于重边选择了最小的那一个 ```c++ #include #include using namespace std; const int maxs = 50; const int INF = 99999; struct AMGraph { int vexs[maxs];//定点表 int arr[maxs][ma…
样例是能过的,刚开始的时候Max设置成了50,除了第一个点以外全是RE,但是Max=10000的时候内存又过大了,稍微小一点后四个点要么RE,要么超时 ```c++ #include #include using namespace std; const int Max=10000; struct AMGraph {…
在讨论《10分求助》回复:
@[Kevin_Mamba](/user/576934) 最终还是用二维做出来了,主要是二维数组中有些行的一些数是0,导致下一行计算的时候用上一行的数据的时候就会出错。 前面的和你是一样的 ```c++ for (int i = 1; i <= m; i++) { for (int v = 1; v <= n; v++…
只对了第一个点 ```c++ #include #include using namespace std; int w[1000];//时间 int c[1000];//价值 int dp[100][100];//第i个物品,恰好装满重量为v的背包 int main(){ int n,m; cin>>n>>m; for…
```c++ #include using namespace std; struct node { int data; node* lchild; node* rchild; }; node* build(int data) { if (data == 0) { return NULL; } node* root =…
在讨论《求助!边界条件》回复:
@[LYM20114](/user/531776) 好像按照这样写是可以的,不过,哥,能帮我改一下本身的吗,因为是套模板,现在还不熟,就不想改了
在讨论《求助!边界条件》回复:
@[LYM20114](/user/531776) 没有设置i耶可是
感觉总体应该问题不大,但是输出的时候所有的样例cha都是没变的 ```c++ #include #include using namespace std; struct food { int s;//酸度 int b;//苦度 }; int n; food arr[10]; int book[100]; long ch…
在讨论《五个RE》回复:
@[レムです](/user/386451) 谢谢大佬 就是想顺便问一下,emm我的码风哪里可以更加改进一下吗,还有就是根据错误类型找问题是说WA的时候自己过一遍代码吗
人有点麻 ```c++ #include using namespace std; int main() { int n = 0, m = 0; cin >> n >> m; int arr[100000]; for (int i = 0; i > arr[i]; } int arr1[100000];//放一个比较数…
在讨论《第三个嫌我答案太长》回复:
@[xixike](/user/158846) 请问有时候如何考虑到这些特殊情况呢?因为平时做题的时候好像总是会漏掉一些情况
在讨论《第三个嫌我答案太长》回复:
@[xixike](/user/158846) 感谢感谢,只要把最后面的 ```c++ if(num==1)//这个东西放在while循环的最前面就行了
在讨论《第三个嫌我答案太长》回复:
Wrong Answer.wrong answer Too long on line 1.
```c++ #include using namespace std; int main() { int num = 0; cin >> num; int arr[10000]; arr[0] = num; int i = 1, a = 1;//a��ͳ��������Ԫ�صĸ��� while (num != 0)…