Skip to content

Commit f150ea6

Browse files
committed
docs: apply code review feedback for Exponentiation and SQL Reformat Department Table
1 parent 8a41c99 commit f150ea6

6 files changed

Lines changed: 1305 additions & 4072 deletions

File tree

Mathematics/Exponentiation by Squaring/leetcode/50. Pow(x, n)/Claude/README detailed.html

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -788,21 +788,6 @@ <h3>🎯 実際の計算比較</h3>
788788
.join('');
789789
}
790790

791-
// 例題の解析を表示
792-
function displayExamples() {
793-
// 例1
794-
const ex1 = myPowWithSteps(2, 10);
795-
document.getElementById('example1').innerHTML = formatSteps(ex1);
796-
797-
// 例2
798-
const ex2 = myPowWithSteps(2.1, 3);
799-
document.getElementById('example2').innerHTML = formatSteps(ex2);
800-
801-
// 例3
802-
const ex3 = myPowWithSteps(2, -2);
803-
document.getElementById('example3').innerHTML = formatSteps(ex3);
804-
}
805-
806791
// インタラクティブデモ
807792
function calculateDemo() {
808793
const base = parseFloat(document.getElementById('baseInput').value);
@@ -831,7 +816,7 @@ <h3>🎯 実際の計算比較</h3>
831816
832817
<div style="color: #ffb74d; margin: 10px 0;">✅ 高速指数演算:</div>
833818
2^7 = 2 × 2^6 (奇数処理)
834-
2^6 = (2^3)^2 = 8^2 (偶数処理)
819+
2^6 = (2^3)^2 = 8^2 (偶数処理)
835820
2^3 = 2 × 2^2 = 2 × 4 = 8 (奇数処理)
836821
2^2 = (2^1)^2 = 2^2 = 4 (偶数処理)
837822
2^1 = 2 × 2^0 = 2 × 1 = 2 (奇数処理)
@@ -862,7 +847,7 @@ <h3>🎯 実際の計算比較</h3>
862847
Step 1: x = 1/2 = 0.5, n = 4 (負の指数変換)
863848
Step 2: 0.5^4 を計算
864849
0.5^4 = (0.5^2)^2 (偶数処理)
865-
0.5^2 = 0.25
850+
0.5^2 = 0.25
866851
0.5^4 = 0.25^2 = 0.0625
867852
868853
<div style="color: #4caf50; margin: 15px 0; padding: 10px; background: rgba(76, 175, 80, 0.1); border-radius: 5px;">

0 commit comments

Comments
 (0)