I’ve tried BFS from each soldier for a given strength but it seems hard to maintain the level which I am in.
So that I’ve got WA for the test:
1
6 6 1
1 2
1 3
2 4
3 5
4 6
5 6
1 3
Can anyone help me to find the right way to do this ?
problem: https://www.spoj.com/problems/AKBAR/21
my solution: https://ideone.com/XpDH6g11
created
last reply
- 1
reply
- 609
views
- 2
users
- 1
like
- 2
links