wa的主要原因是数组开的太2333.
你把每个数组都多开5位就过了。因为卡着范围开数组有的时候(经常)会出bug
就是这样
```cpp
int a[105], b[105], c[105];
char temp[105];
```
还有。养成一个好习惯。数组在主函数外面开!!!
```cpp
#include <iostream>
#include <algorithm>
#include <cstring>
#include <string>
using namespace std;
int ans, z;
int a[105], b[105], c[105];
char temp[105];
string answ;
string num;
string add(string n1, string n2)//高精度
{
int lena=n1.size()-1, lenb=n2.size()-1,lenc=0,x=0;
memset(a, 0, sizeof(a));
memset(b, 0, sizeof(b));
memset(c, 0, sizeof(c));
```
思路没有错
by Arcturus1350 @ 2017-11-16 18:56:31
好的谢谢!!!
by Hengzhili @ 2017-11-19 13:16:35