UVA 913 - Joana and the Odd Numbers

UVA Sep 1, 2020

Problem PDF

Solution:

#include
int main()
{
    long long n;
    while (scanf("%lld",&n)==1)
    printf("%lld\n",((n*(n+2))/2)*3-6);
return 0;
}
https://github.com/Shipu/OnlineJudgeProblemSolutionWithCPlusPlus/tree/master/uva/913/913.cpp

Tags

Great! You've successfully subscribed.
Great! Next, complete checkout for full access.
Welcome back! You've successfully signed in.
Success! Your account is fully activated, you now have access to all content.