Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
3 モジュロ 11 が 3 に等しいのはなぜですか? コーディング構文の式は通常
3 % 11
これは 3 を 11 で割った余りですよね?それが余りになるので、結果は 11 になるはずです。私は何を間違って理解していますか?
3 / 11 = 0 残り 3。定義により、任意の n mod m に対する答えが m 以上になることはありません。
なぜなら
3 / 11 == 0 3 % 11 == 3 0 * 11 + 3 == 3
0 ------- 11 | 3 | 0 | ------- 3 = Answer