GoLang Solution For UVa Online Judge: 10036 - Divisibility
GO Solution For UVa 10036 - Divisibility. In this post we will see how we can solve this challenge in GoLang for UVa Online Judge.
Consider an arbitrary sequence of integers. One can place + or - operators between integers in the sequence, thus deriving different arithmetical expressions that evaluate to different values. Let us, for example, take the sequence: 17, 5, -21, 15. There are eight possible expressions:
17 + 5 + -21...
You can find the full details of the problem Divisibility at UVa Online Judge
2 4 7 17 5 -21 15 4 5 17 5 -21 15
Divisible Not divisible
Solution: Please check the main.go snippet for the solution.
Solution originally posted at: Github by @codingsince1985