//var S=readLine()!.characters.map{String($0)},a=[0,0];for i in 0..<2{for(j,c)in S.enumerate(){if j%2^i != Int(c){a[i]++}}};print(min(a[0],a[1]))
var a=[0,0];for i in 0..<2{readLine()!.characters.map{String($0)}.enumerate().forEach{j,c in if j%2^i != Int(c){a[i]++}}};print(min(a[0],a[1]))