GO Solution For UVa 10790 - How Many Points of Intersection?. In this post we will see how we can solve this challenge in GoLang for UVa Online Judge.

Problem Description

We have two rows. There are a dots on the top row and b dots on the bottom row. We draw line segments connecting every dot on the top row with every dot on the bottom row. The dots are arranged in such a way that the number of internal intersections among the line segments is maximized. To achieve t

...

You can find the full details of the problem How Many Points of Intersection? at UVa Online Judge

Sample Input

2 2
2 3
3 3
0 0

Sample Output

1
3
9

Solution: Please check the main.go snippet for the solution.

Solution originally posted at: Github by @codingsince1985