The PDF version of this problem can be downloaded here.
2 2 2 1000000000 1 1 1 2 2 2 2 3 2 2 1000000000 1 1 1 2 2 2 3 4
4 -1
Migrated from old NTUJ.
eddy