mirror of
https://github.com/VitaAetaerna/SubnetExerciseGenerator.git
synced 2025-10-15 14:12:42 +02:00
Compare commits
2 Commits
a949633876
...
main
Author | SHA1 | Date | |
---|---|---|---|
|
7bfe22aab1 | ||
|
fccd0ce51d |
6
main.py
6
main.py
@@ -1,6 +1,6 @@
|
||||
import math
|
||||
import random
|
||||
|
||||
print("Made by VitaAeterna and NekoSilvertail https://github.com/VitaAetaerna/SubnetExerciseGenerator/")
|
||||
def intToDotted(ip):
|
||||
# input: ip
|
||||
# determins dotted decimal format for given ip as int
|
||||
@@ -152,4 +152,6 @@ if __name__ == '__main__':
|
||||
subnet=analyseSubnet(net.get("nid")+listnetwork*2**(32-newprefix), newprefix)
|
||||
print("Network {}: NID: {} BC: {}".format(listnetwork, printDotted(subnet.get("nid")), printDotted(subnet.get("bc"))))
|
||||
print("\nSubnets:")
|
||||
listSubnets(ip, prefix, newprefix)
|
||||
listSubnets(ip, prefix, newprefix)
|
||||
input("\nPress enter to exit\n")
|
||||
|
||||
|
Reference in New Issue
Block a user