Thank you for the opportunity to help you with your question!

function H(n)

if n<1 thenprint "n cannot be negative"

if n<1 then

print "n cannot be negative"

if n=1 thenreturn 1else n>1 thenreturn H(n-1) + 6n -6

if n=1 then

return 1

else

n>1 then

return H(n-1) + 6n -6

precondition n>0

added if n<1 in order to avoid run time errors.

Secure Information

Content will be erased after question is completed.

Enter the email address associated with your account, and we will email you a link to reset your password.

Forgot your password?

Sign Up