let n = Int(readLine()!)!
let v = readLine()!.characters.split(" ").map{Int(String($0))!}
var num = (0..<2).map{_ in (0..<100000).map{_ in 0}}
for (i, vi) in v.enumerate() {
    num[i%2][vi-1] += 1
}
var first = [0, 0]
var second = [0, 0]
for i in 0..<100000 {
    for j in 0..<2 {
        if num[j][i] > first[j] {
            (first[j], second[j]) = (num[j][i], first[j])
        } else if num[j][i] > second[j] {
            second[j] = num[j][i]
        }
    }
}
if num[0].indexOf(first[0]) != num[1].indexOf(first[1]) {
    print(n - (first[0]+first[1]))
} else {
    print(n - max(first[0]+second[1], second[0]+first[1]))
}