Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F120272786
arithmetic_series.cpp
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Thu, Jul 3, 04:05
Size
191 B
Mime Type
text/x-c
Expires
Sat, Jul 5, 04:05 (2 d)
Engine
blob
Format
Raw Data
Handle
27165078
Attached To
R9360 PCSC_git
arithmetic_series.cpp
View Options
#include <iostream>
int arithmetic(int i) {
if (i == 1)
return 1;
return i + arithmetic(i - 1);
}
int main() {
int a = 5;
std::cout << arithmetic(a);
std::cout << std::endl;
}
Event Timeline
Log In to Comment