← Home
```go
package main

import (
	"bufio"
	"fmt"
	"math"
	"math/rand"
	"os"
	"sort"
)

type Point struct {
	x, y float64
}

var points []Point

func eval(x, y float64) float64 {
	min1, min2 := 1e20, 1e20
	for i := 0; i < len(points); i++ {
		dx := x - points[i].x
		dy := y - points[i].y
		d2 := dx*dx + dy*dy
		if d2 < min1 {
			min2 = min1
			min1 = d2
		} else if d2 < min2 {
			min2 = d2
		}
	}
	return min2
}

func optimize(startX, startY, w, h float64) float64 {
	x, y := startX, startY
	best := eval(x, y)

	maxStep := w
	if h > w {
		maxStep = h
	}
	step := maxStep

	for step > 1e-11 {
		moved := false
		baseAngle := rand.Float64() * 2 * math.Pi
		for i := 0; i < 24; i++ {
			angle := baseAngle + float64(i)*math.Pi/12
			nx := x + step*math.Cos(angle)
			ny := y + step*math.Sin(angle)
			if nx < 0 {
				nx = 0
			}
			if nx > w {
				nx = w
			}
			if ny < 0 {
				ny = 0
			}
			if ny > h {
				ny = h
			}

			e := eval(nx, ny)
			if e > best {
				best = e
				x = nx
				y = ny
				moved = true
				step *= 1.2
				if step > maxStep {
					step = maxStep
				}
				break
			}
		}
		if !moved {
			step *= 0.5
		}
	}
	return best
}

type StartPoint struct {
	p   Point
	val float64
}

func main() {
	in := bufio.NewReader(os.Stdin)
	var wInt, hInt, n int
	if _, err := fmt.Fscan(in, &wInt, &hInt, &n); err != nil {
		return
	}

	w, h := float64(wInt), float64(hInt)

	points = make([]Point, n)
	for i := 0; i < n; i++ {
		var x, y float64
		fmt.Fscan(in, &x, &y)
		points[i] = Point{x, y}
	}

	rand.Seed(42)

	var sp []StartPoint
	gridX := 100
	gridY := 100
	grid := make([][]float64, gridX+1)
	for i := 0; i <= gridX; i++ {
		grid[i] = make([]float64, gridY+1)
		for j := 0; j <= gridY; j++ {
			x := w * float64(i) / float64(gridX)
			y := h * float64(j) / float64(gridY)
			grid[i][j] = eval(x, y)
		}
	}

	for i := 0; i <= gridX; i++ {
		for j := 0; j <= gridY; j++ {
			isLocalMax := true
			for dx := -1; dx <= 1; dx++ {
				for dy := -1; dy <= 1; dy++ {
					if dx == 0 && dy == 0 {
						continue
					}
					ni, nj := i+dx, j+dy
					if ni >= 0 && ni <= gridX && nj >= 0 && nj <= gridY {
						if grid[ni][nj] > grid[i][j] {
							isLocalMax = false
						}
					}
				}
			}
			if isLocalMax {
				x := w * float64(i) / float64(gridX)
				y := h * float64(j) / float64(gridY)
				sp = append(sp, StartPoint{Point{x, y}, grid[i][j]})
			}
		}
	}

	sort.Slice(sp, func(i, j int) bool {
		return sp[i].val > sp[j].val
	})

	limit := 400
	if len(sp) < limit {
		limit = len(sp)
	}

	globalBest := -1.0
	for i := 0; i < limit; i++ {
		best := optimize(sp[i].p.x, sp[i].p.y, w, h)
		if best > globalBest {
			globalBest = best
		}
	}

	fmt.Printf("%.10f\n", math.Sqrt(globalBest))
}
```