Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6945267
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T13:24:51+00:00 2026-05-27T13:24:51+00:00

Im going over the solution to a previous midterm of mine below, and i

  • 0

Im going over the solution to a previous midterm of mine below, and i dont understand line 9 in the pseudo code. For the first iteration when s=1 and i=1, A[i] would equal 12, whixh would make C[i,s] equal to C[i-1,s]

But wouldnt C[i-1,s] throw an error since i would now be 0 (out of bounds?)

enter image description here

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T13:24:51+00:00Added an answer on May 27, 2026 at 1:24 pm

    Line 9:

    C[i,s] = C[i-1,s].
    

    Note that in subproblem c you have already defined:

    C[0,s] = 0 for all s.
    

    So C[1-1, s] will return a 0.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I was going over some old C code (listed below) with a view to
I am going over/studying the facebook code that was leaked in 2007, I notice
So we start Scrum today and start going over story points estimates. The first
I'm going over the jquery widget here: http://blog.davidpadbury.com/2010/10/11/bdd-testing-of-jquery-plugins-using-jasmine/ The plugin is called like so:
I am going over a past paper for a database course I am taking
I've moved to a new project team and while going over the codebase, found
as we know, the loop X instruction is going over X until ECX =
I'm going back over an old project where I added preprocessor functionality to Essence'
I'm designing a database application where data is going to change over time. I
I sweated over the question above. The answer I'm going to supply took me

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.