menu
Qammunity
Login
Register
My account
Edit my Profile
Private messages
My favorites
Ask a Question
Questions
Unanswered
Tags
Categories
Ask a Question
Give a recursive algorithm for finding the sum of the first n odd positive integers.
asked
Jul 4, 2016
104k
views
1
vote
Give a recursive algorithm for finding the sum of the
first n odd positive integers.
Computers and Technology
high-school
MS Berends
asked
by
MS Berends
9.5k
points
answer
comment
share this
share
0 Comments
Please
log in
or
register
to add a comment.
Please
log in
or
register
to answer this question.
1
Answer
3
votes
I'm writing that in some sort of pseudocode; if you don't understand it, feel free to ask for more details in the comments.
function sumOdd(n)
if n==1 then
return 1
end if
return (sumOdd(n-1))+(n*2-1)
end function
Jordan Hudson
answered
Jul 8, 2016
by
Jordan Hudson
9.0k
points
ask related question
comment
share this
0 Comments
Please
log in
or
register
to add a comment.
← Prev Question
Next Question →
Related questions
asked
Jun 16, 2017
194k
views
A house blueprint has a scale of I in : 4 PL-The length and width of each room in the actual house are shown in me able Complete 1 A 1 . the table by finding the length and width of each room on the blueprint
Nouvist
asked
Jun 16, 2017
by
Nouvist
7.9k
points
Mathematics
middle-school
1
answer
0
votes
194k
views
asked
Mar 2, 2018
138k
views
Women born with an extra x chromosome (xxx) are generally healthy and indistinguishable in appearance from normal xx women. what is a likely explanation for this finding? how could you test this explanation?
William Linton
asked
Mar 2, 2018
by
William Linton
8.3k
points
Biology
high-school
1
answer
5
votes
138k
views
asked
Jul 21, 2020
96.3k
views
Patrick’s speech about foraging (finding edible plants in the wild) ends with this final statement: " Although your wallet may be empty, with foraging, your plate can always be full." What literary scheme
Arpit Gupta
asked
Jul 21, 2020
by
Arpit Gupta
7.2k
points
English
high-school
1
answer
2
votes
96.3k
views
Ask a Question
Welcome to QAmmunity.org, where you can ask questions and receive answers from other members of our community.
9.4m
questions
12.2m
answers
Other Questions
“What does it mean when we “rework” copyrighted material?”
The book shows how to add and subtract binary and decimal numbers. However, other numbering systems are also very popular when dealing with computers. The octal (base 8) numbering system is one of these.
Seven basic internal components found in a computer tower
Please help me ! All you do is just put it it all in your own words ! Please this is for my reported card!i don't know how to put it in my own words because my English is not that good!
Disadvantages of using animation in advertising? advantages and disadvantages of using animation for education? advantages and disadvantages of using animation in entertainment?
Twitter
WhatsApp
Facebook
Reddit
LinkedIn
Email
Link Copied!
Copy
Search Qammunity