ルジャンドル記号
平方剰余の法則を含む上記の性質をルジャンドル記号を評価するために使用できる。例えば
( 12345 331 ) = ( 3 331 ) ( 5 331 ) ( 823 331 ) = ( 3 331 ) ( 5 331 ) ( 161 331 ) = ( 3 331 ) ( 5 331 ) ( 7 331 ) ( 23 331 ) = ( − 1 ) ( 331 3 ) ( 331 5 ) ( − 1 ) ( 331 7 ) ( − 1 ) ( 331 23 ) = − ( 1 3 ) ( 1 5 ) ( 2 7 ) ( 9 23 ) = − ( 1 3 ) ( 1 5 ) ( 2 7 ) ( 3 2 23 ) = − ( 1 ) ( 1 ) ( 1 ) ( 1 ) = − 1. {\displaystyle {\begin{aligned}\left({\frac {12345}{331}}\right)&=\left({\frac {3}{331}}\right)\left({\frac {5}{331}}\right)\left({\frac {823}{331}}\right)\\&=\left({\frac {3}{331}}\right)\left({\frac {5}{331}}\right)\left({\frac {161}{331}}\right)\\&=\left({\frac {3}{331}}\right)\left({\frac {5}{331}}\right)\left({\frac {7}{331}}\right)\left({\frac {23}{331}}\right)\\&=(-1)\left({\frac {331}{3}}\right)\left({\frac {331}{5}}\right)(-1)\left({\frac {331}{7}}\right)(-1)\left({\frac {331}{23}}\right)\\&=-\left({\frac {1}{3}}\right)\left({\frac {1}{5}}\right)\left({\frac {2}{7}}\right)\left({\frac {9}{23}}\right)\\&=-\left({\frac {1}{3}}\right)\left({\frac {1}{5}}\right)\left({\frac {2}{7}}\right)\left({\frac {3^{2}}{23}}\right)\\&=-(1)(1)(1)(1)\\&=-1.\end{aligned}}}