FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Fix loop range in viralAdvertising function by shad03152015 · Pull Request #39 · sapanz/Hackerrank-Problem-Solving-Python-Solutions · GitHub

Fix loop range in viralAdvertising function - #39

Open
shad03152015 wants to merge 1 commit into
sapanz:masterfrom
shad03152015:patch-2
Open

Fix loop range in viralAdvertising function#39
shad03152015 wants to merge 1 commit into
sapanz:masterfrom
shad03152015:patch-2

Conversation

Copy link
Copy Markdown

Critical bug: Should be range(n) to process all n days.

range(1, n-1): For n=5, runs i=1,2,3 (3 iterations, skips days 1+5)

Correct: range(n) runs i=0,1,2,3,4 (5 iterations)

Critical bug: Should be range(n) to process all n days.

range(1, n-1): For n=5, runs i=1,2,3 (3 iterations, skips days 1+5)

Correct: range(n) runs i=0,1,2,3,4 (5 iterations)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant


Back | FazBrowse Home | New Git URL