AccurateLee | Codeforces Round 652 (Div 2) | Code Solution
AccurateLee | Codeforces Round 652 (Div 2) | Code Solution C++ code given below: #include < bits / stdc ++. h > using namespace std ; int main () { int t ; cin >> t ; while ( t --) { int n ; cin >> n ; string s ; cin >> s ; int flag = 0 ; for ( int i = 0 ; i < s . length ()- 1 ; i ++) { if ( s [ i ]== '1' && s [ i + 1 ]== '0' ) { flag = 1 ; break ; } } if ( flag == 0 ) cout << s << endl ; else { for ( int i = 0 ; i < s . length (); i ++) { if ( s [ i ]== '0' ) cout << "0" ; else { cout << "0" ; break ; ...