From 4de51626651b55702bee1c3b7aed9a2746e592cb Mon Sep 17 00:00:00 2001 From: rcxpony Date: Sun, 2 Mar 2025 17:10:02 +0500 Subject: [PATCH] optimized --- sources/main.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sources/main.cpp b/sources/main.cpp index 402579b..7da1d13 100644 --- a/sources/main.cpp +++ b/sources/main.cpp @@ -76,8 +76,8 @@ inline void bitwiseInverse(const unsigned char* key, Key& inverted) noexcept { } inline unsigned char getOnes(const Key& value) noexcept { int leadOnes = 0; - for (unsigned char i = 0; i < 17; i++) { - if (value[0] != 0xFF) return leadOnes; + for (unsigned char i = 0; i < 32; i++) { + if (value[0] != 0xFF && value[1] != 0xFF) return leadOnes; if (value[i] == 0xFF) { leadOnes += 8; } else {