package main import ( "fmt" "sort" ) func main() { var N, rlt int fmt.Scan(&N) if N == 1 { fmt.Println("1") return } a := make([]int, N) for i := 0; i < N; i++ { fmt.Scan(&a[i]) } sort.Ints(a) for i := 1; i < N-1; i++ { if a[i] != a[i-1] && a[i] != a[i+1] { rlt++ } } if a[0] != a[1] { rlt++ } if a[N-1] != a[N-2] { rlt++ } fmt.Println(rlt) }