How to effectively keep the MAC address as int64?


#1

How to effectively keep the MAC address as int64 not as a string ? A have a lot of strings … are to hevy .
Paul


#2

Maybe :

julia> parse(Int, "001b44113ab7", 16)
117106096823

julia> base(16, 117106096823, 12)
"001b44113ab7"

#3

THX. Nice and simpy, only UPPER CASE and lowercase are changed. Some sugestion ?

julia> parse(Int, “E58329B3EAC4”, 16)
252351503133380

julia> base(16, 252351503133380, 12)
“e58329b3eac4”

julia> parse(Int, “000102d8dff5”, 16)
4342734837

julia> base(16, 4342734837, 12)
“000102d8dff5”

Paul


#4
julia> uppercase(base(16, 252351503133380, 12))
"E58329B3EAC4"