Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Function power2(limit As Integer) As Long
- Dim counter As Long
- counter = 0
- While 2^counter < limit
- counter = counter +1
- Wend
- power2 = 2^ (counter - 1)
- End Function
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement