From 9dfb2c6a764bdf8b57c758b54ce904a703c50858 Mon Sep 17 00:00:00 2001 From: Choudhary Reyan Khan <93575436+ReyanChaudhary@users.noreply.github.com> Date: Thu, 20 Oct 2022 16:08:45 +0530 Subject: [PATCH] Create CodeChef_Non_Adjacent_Flips.cpp HACKTOBER FEST 2022 --- CodeChef_Non_Adjacent_Flips.cpp | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 CodeChef_Non_Adjacent_Flips.cpp diff --git a/CodeChef_Non_Adjacent_Flips.cpp b/CodeChef_Non_Adjacent_Flips.cpp new file mode 100644 index 0000000..567b860 --- /dev/null +++ b/CodeChef_Non_Adjacent_Flips.cpp @@ -0,0 +1,30 @@ +#include +using namespace std; + +int main() { + // your code goes here + int t; cin>>t; + while(t--){ + int n; cin>>n; string s; cin>>s; + int k = 0, z=0; + for(int i=0;i0){ + cout<<2<