-
Notifications
You must be signed in to change notification settings - Fork 0
/
VihnKhoaTon2Topo.py
executable file
·22 lines (20 loc) · 1.04 KB
/
VihnKhoaTon2Topo.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# submitted by Vihn Khoa Ton, OMSCS Fall 2018
## Topology 3 ########################################
# 3 --- 9 --- 1 | Answer: 3 9 --- 1
# | \ | / | | \ / |
# | \ | / | | \ / |
# 8 --- 6 --- 4 | 8 --- 6 4
# | / | \ | | / | |
# | / | \ | | / | |
# 5 --- 2 --- 7 | 5 2 7
#
#
topo = { 5 : [8, 6, 2], # Answer: 1 - 4, 1 - 6, 1 - 9
9 : [3, 1, 6], # 2 - 6
1 : [9, 6, 4], # 3 - 6
4 : [1, 6, 7], # 4 - 1, 4 - 7
2 : [6, 5, 7], # 5 - 6
3 : [8, 6, 9], # 6 - 1, 6 - 2, 6 - 3, 6 - 5, 6 - 8
8 : [3, 5, 6], # 7 - 4
7 : [4, 6, 2], # 8 - 6
6 : [1, 7, 4, 9, 8, 5, 3, 2] } # 9 - 1