这名用户暂未设置签名。
追踪最近的用户名外显变动记录。
最近的文章、讨论、云剪贴板与社区记录
```cpp #include using namespace std; int n; string str; void f(string s) { if (s.size() == 1) { if (s == "1")cout s.size())cout s.size())cout > n >> str; f(str)…
```cpp #include using namespace std; int a[10001]; long long dp[10001]; int n; int main() { cin >> n; for (int i = 1; i > a[i]; dp[1] = a[1];//初始化边界条件 for (int…
在讨论《关于double和pow》回复:
@[chienyu](/user/544069) pow的函数重载结果都是返回double类型或科学计数法的表示,本题用longlong接受pow的计算结果当然没问题,只是会有缩窄转换,我本地编译器没通过,所以改用double,也可long long(pow),我学疏才浅,您看我说的对吗
这道题不是说double过不了,而是pow和double的组合如果计算结果过大,会直接编程科学计数法,导致结果错误。 ```cpp cout <<fixed<<setprecision(0)<< ans;//如果是double,数字过大会变成科学计数法 ```
在讨论《本地可以跑,提交编译失败》回复:
```cpp #include #include using namespace std; int n; char s[200]; int a[200],b[200]; int cnt, lens, cur; bool check() { for (int i = lens+1 - 1; i > 0; i--) { i…
在讨论《本地可以跑,提交编译失败》回复:
@[F12aaaaaaa](/user/920043) 感谢感谢,做题做麻了;)
```c #include using namespace std; int n; char s[200]; int a[200],b[200]; int cnt, lens, cur; bool check() { for (int i = lens+1 - 1; i > 0; i--) { if (a[i]!=a[…