Answers for "mod 10e9+7 in java"

0

mod 10e9+7 in java

mod = 1000000007;

int a = (b * c)%mod; // It might overflow even we did mod;

int a =  (int)((1LL * b * c)%mod); // its correct
Posted by: Guest on August-09-2021

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language