Hi is there way to check that your code is Recursion or not in c++? I write code but someone tell me that it isn't Recursion. I want to make sure.
#include <iostream>
#include <conio.h>
using namespace std;
bool winding(string str, int len) {
    int counttrue = 0;
    for(int i = 0; i < len; i++){
        if(str[i] == '1') counttrue++;
        else if(i != len - 1 && str[i] == '0' && str[i + 1] == '0') {
            counttrue += 2; i++;
        }
    }
    return (counttrue == len);
}
int main() {
  string strwinding;
  cin >> strwinding;
  cout << winding(strwinding, strwinding.length()) << endl;
  cout << "Continue...";
  getch();
  return 0;
}
 
    