Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- bin := "0001 0100 1001 1011 0110"
- MsgBox, % Bin2Dec(bin)
- Bin2Dec(BinStr) {
- arr := StrSplit(BinStr,, " ")
- max := arr.MaxIndex()
- Loop % max
- dec += arr[max - A_Index + 1] << (A_Index - 1)
- Return dec
- }
Add Comment
Please, Sign In to add comment