0_0_36664171_28149.cpp: In function 'void solve()': 0_0_36664171_28149.cpp:34:6: error: redeclaration of 'int cnt' int cnt = 0; ^ 0_0_36664171_28149.cpp:23:6: note: 'int cnt' previously declared here int cnt = 0; ^