diff --git a/Other Algorithms/Fit_square_in_equilateral_triangle.cpp b/Other Algorithms/Fit_square_in_equilateral_triangle.cpp new file mode 100644 index 000000000..7dee85b91 --- /dev/null +++ b/Other Algorithms/Fit_square_in_equilateral_triangle.cpp @@ -0,0 +1,18 @@ + #include + #include + using namespace std; + + int main(){ + + int cases, base; + cin>>cases; + + while(cases--){ + + cin>>base; + base=(base/2)-1; + base=(base*(base+1))/2; + cout<