0401.12 (Score 65) 3b51672
Details:
1.sort cost, and in V' or not.
eg. 1: cost 2, in V'. 2: cost 5, not in V'. 3: cost 10, in V'. 4: cost 8, not in V'.
AdjList: 1->3->2->4
2.multi-loop-2-layer DFS.
search 2 layer for n loops, to sort the adj-list.
(n=2 seems to be better than n>2. But it does Not have too much difference with n=1 >_<)
3.Part 1: 3-layer BFS
4.balance searching-time for each BFS out-path .
5.Part 2: DFS
6.update costSum each step. if costSum greater than the least totalCost, backward and stack pop.
set the initial totalCost **1200**
This function will start in the beginning.
0330.4 (Score 60) 68c59c8
Details:
1.sort cost, and in V' or not.
eg. 1: cost 2, in V'. 2: cost 5, not in V'. 3: cost 10, in V'. 4: cost 8, not in V'.
AdjList: 1->3->2->4
2.multi-loop-2-layer DFS.
search 2 layer for n loops, to sort the adj-list.
(n=2 seems to be better than n>2. But it does Not have too much difference with n=1 >_<)
3.balance searching-time for each out-edge of start vex.
4.update costSum each step. if costSum greater than the least totalCost, backward and stack pop.
set the initial totalCost **1200**
This function will start in the beginning.
Case_ID Cost Time
1 4 1
2 16 1
3 31 1
4 62 1
5 56 30
6 146 9900
7 257 9900
8 0 0
9 481 9900
10 0 0
11 0 9900
12 640 9900
13 781 0
14 1147 9900
15 0 0
0330.1 commit soon
Details:
1.sort cost, and in V' or not.
eg. 1: cost 2, in V'. 2: cost 5, not in V'. 3: cost 10, in V'. 4: cost 8, not in V'.
AdjList: 1->3->2->4
2.2-layer DFS.
search 2 layer to sort the adj-list.
3.balance searching-time for each out-edge of start vex.
4.update costSum each step. if costSum greater than the least totalCost, backward and stack pop.
set the initial totalCost **1200**
This function will start in the beginning.
Case_ID Cost Time
1 4 1
2 16 1
3 31 1
4 62 1
5 56 30
6 146 9900
7 257 9900
8 0 0
9 441 9900
10 0 0
11 0 9900
12 640 9900
13 781 0
14 1147 9900
15 0 0
Details:
1.sort cost, and in V' or not.
eg. 1: cost 2, in V'. 2: cost 5, not in V'. 3: cost 10, in V'. 4: cost 8, not in V'.
AdjList: 1->3->2->4
2.balance searching-time for each out-edge of start vex.
3.update costSum each step. if costSum greater than the least totalCost, backward and stack pop.
set the initial totalCost **1200**
This function will start in the beginning.
Case_ID Cost Time
1 4 1
2 16 1
3 31 1
4 62 1
5 56 30
6 157 9900
7 0 0
8 0 0
9 448 9900
10 0 0
11 1168 9900
12 575 9900
13 0 0
14 1109 9900
15 0 0
Details:
1.sort cost, and in V' or not.
eg. 1: cost 2, in V'. 2: cost 5, not in V'. 3: cost 10, in V'. 4: cost 8, not in V'.
AdjList: 1->3->2->4
2.balance searching-time for each out-edge of start vex.
3.update costSum each step. if costSum greater than the least totalCost, backward and stack pop.
set the initial totalCost **1000**
This function will start in the beginning.
Case_ID Cost Time
1 4 1
2 16 1
3 31 1
4 62 1
5 56 30
6 157 9900
7 0 0
8 0 0
9 448 9900
10 0 0
11 0 0
12 575 9900
13 0 0
14 984 9900
15 0 0
Details:
1.sort cost, and in V' or not.
eg. 1: cost 2, in V'. 2: cost 5, not in V'. 3: cost 10, in V'. 4: cost 8, not in V'.
AdjList: 1->3->2->4
2.balance searching-time for each out-edge of start vex.
3.update costSum each step. if costSum greater than the least totalCost, backward and stack pop.
This function will start after the first right route found.
Case_ID Cost Time
1 4 1
2 16 1
3 31 1
4 62 1
5 56 30
6 157 9900
7 0 100000000
8 0 100000000
9 448 9900
10 0 100000000
11 1168 9900
12 575 9900
13 0 100000000
14 0 100000000
15 0 100000000
Details:
1.sort cost.
2.balance searching-time for each out-edge of start vex.
Case_ID Cost Time Case_Score
1 4 1.0 100.0
2 16 1.0 100.0
3 31 1.0 100.0
4 62 1.0 100.0
5 56 30.0 79.98
6 157 9900.0 82.9
7 0 100000000 0.0
8 0 100000000 0.0
9 0 100000000 0.0
10 0 100000000 0.0
Details:
search from v'
Case_ID Cost Time Case_Score
1 4 10.0 66.32
2 16 10.0 67.47
3 31 20.0 62.98
4 62 310.0 60.27
5 56 2140.0 61.73
6 143 9900.0 95.1
7 0 100000000 0.0
8 0 100000000 0.0
9 0 0 0.0
10 0 100000000 0.0