diff --git a/src/main/java/com/github/underscore/U.java b/src/main/java/com/github/underscore/U.java
index <HASH>..<HASH> 100644
--- a/src/main/java/com/github/underscore/U.java
+++ b/src/main/java/com/github/underscore/U.java
@@ -2060,7 +2060,7 @@ public class U<T> {
         final long passwordLength = Math.abs(UUID.randomUUID().getLeastSignificantBits() % MIN_PASSWORD_LENGTH_8)
             + MIN_PASSWORD_LENGTH_8;
         for (int index = 0; index < passwordLength; index += 1) {
-            final int passIndex = (int) (passwords.length * index / passwordLength);
+            final int passIndex = (int) (passwords.length * (long) index / passwordLength);
             final int charIndex = (int) Math.abs(
                 UUID.randomUUID().getLeastSignificantBits() % passwords[passIndex].length());
             result.append(passwords[passIndex].charAt(charIndex));
Fix lgtm warning.