Skip to content

How we are handling -ve values by sum of mod value 10^9+7. #3

Description

@abhik235

if(sum < 0) {
sum = sum + mod;
}

I didn't get this part. However -ve value is also possible then if we add 10^9+7 it will become +ve which is wrong. Please clarify this.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions