最短C++11代码诞生!

P1001 A+B Problem

lucas1522 @ 2020-01-27 21:30:52

输入迭代器,您值得拥有

#include<bits/stdc++.h>
std::istream_iterator<int> in(std::cin),eof;
main(){
    std::cout<<std::accumulate(in,eof,0);
}

by 嫐嬲巭孬 @ 2020-01-28 11:58:03

main(){int a,b;printf("%d",scanf("%d%d",&a,&b)-2+a+b);}

by lijiawei20 @ 2020-01-28 13:55:24

真好


by lijiawei20 @ 2020-01-28 13:55:47

还用迭代器?


by flowerfell @ 2020-01-28 20:16:36

楼主好傻楼主真棒


by djwj233 @ 2020-01-28 23:47:20

orzorz


by 英雄趁年少6 @ 2020-01-29 22:13:09

我们可以尝试将代码变成一行写


by _Time_Limit_Error_ @ 2020-02-06 10:50:03

@英雄趁年少6 头文件???


by _Time_Limit_Error_ @ 2020-02-06 11:37:57

@英雄趁年少6 既然头文件要占一行那我们最好用python写


by 妙神 @ 2020-02-11 14:33:55

楼主是怕不是个傻子楼主是个天才!!


by Ca1JH @ 2020-02-16 17:56:13

@_Time_LimitError GoC它不香吗


上一页 | 下一页