#include<iostream> using namespace std; double SqrtNumber (double num){ if(num<=0){ return 0; } int counter = ceil(num/2); for(int i=2;i<=counter;i++){ if(i*i == num){ return i; } } return 0; }