What's new

Help Pahelp mga lods (C PROGRAMMING)

vude24

Leecher
Joined
Feb 9, 2022
Posts
2
Reaction
0
Oh! Another secret intel came in! It turns out that the gang members tattoos aren't merely a fashion statement, it is also the number of weapons the Wakwak has given them. Cody also found out that the total number of tattoos of all the gang members is n. Now, to determine how many weapons the gang has in total, Cody has to get the sum of all odd numbers from 0 to n.
Input
1. Value of n
Output
The first line will contain a message prompt to input the value of n. The second line contains the sum of all odd numbers from 0 to n.
Enter·n:·5
Sum·=·9
 
Top