Created
May 4, 2020 10:42
-
-
Save emilgaripov/e51347bf8ce77a861ce4382f689b00d4 to your computer and use it in GitHub Desktop.
Example TypeError
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
''' | |
Задание 4.7 | |
Преобразовать MAC-адрес mac в двоичную строку такого вида: | |
'101010101010101010111011101110111100110011001100' | |
Ограничение: Все задания надо выполнять используя только пройденные темы. | |
''' | |
mac = 'AAAA:BBBB:CCCC' | |
mac_ = mac.strip().split(':') | |
mac_ = ''.join(mac_) | |
mac_ = bin(mac_) | |
mac_ = mac_.lstrip('0b') | |
print(mac_) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment