Please guide how to solve ques

This is my code. Please tell me why am I not able to print the upper half of this hollow diamond pattern.

hi @akshat1409, first try to make 3 4 test cases on paper and then write a code for general n where you dont have to specifically mention for (n == 3) or any other no.

please send solution i am not able to solve it

@akshat1409
refer
https://ide.codingblocks.com/s/647536?_ga=2.128682956.1349480821.1650699623-564174853.1650699623