题解 | #牛牛的西格玛#
牛牛的西格玛
https://www.nowcoder.com/practice/c6b750ee8853484f8dbf14b9531b501f
#include<stdio.h> int x=0; void sum(int n) { x+=n; if(n==0) return ; else return sum(n-1); } int main() { int n; scanf("%d",&n); sum(n); printf("%d",x); return 0; }