1 To 100000000 i = i + 1 Next Dim j As Variant j = 0 For j = 1 To 100000000 j = j + 1 Next k = 0 For k = 1 To 100000000 k = k + 1 Next 変数の型が違う 型の宣言なし = Variant
1 To 100000000 i = i + 1 Next Dim j As Variant j = 0 For j = 1 To 100000000 j = j + 1 Next k = 0 For k = 1 To 100000000 k = k + 1 Next バインディング 早期バインディング 遅延バインディング 遅延バインディング 型の宣言なし = Variant
= 1 To 100000000 i = i + 1 Next 処理時間(秒) 早期 遅延 遅延 1回目 2回目 3回目 平均 Dim j As Variant j = 0 For j = 1 To 100000000 j = j + 1 Next k = 0 For k = 1 To 100000000 k = k + 1 Next
= 1 To 100000000 i = i + 1 Next 処理時間(秒) 早期 遅延 遅延 1回目 64 66 2回目 65 65 3回目 64 64 平均 64 65 Dim j As Variant j = 0 For j = 1 To 100000000 j = j + 1 Next k = 0 For k = 1 To 100000000 k = k + 1 Next
= 1 To 100000000 i = i + 1 Next 処理時間(秒) 早期 遅延 遅延 1回目 3 64 66 2回目 4 65 65 3回目 3 64 64 平均 3 64 65 Dim j As Variant j = 0 For j = 1 To 100000000 j = j + 1 Next k = 0 For k = 1 To 100000000 k = k + 1 Next
= 1 To 100000000 i = i + 1 Next 処理時間(秒) 早期 遅延 遅延 1回目 3 64 66 2回目 4 65 65 3回目 3 64 64 平均 3 64 65 Dim j As Variant j = 0 For j = 1 To 100000000 j = j + 1 Next k = 0 For k = 1 To 100000000 k = k + 1 Next 20倍以上!!