please help me i always ran in to problem when i have to make lower part of patterns …
i struggle to find stopping conditions for loops such that it work for all value of N’s .
here is my code …please explain
it will be great help …
please help me i always ran in to problem when i have to make lower part of patterns …
i struggle to find stopping conditions for loops such that it work for all value of N’s .
here is my code …please explain
it will be great help …
Hello @Diwyanshu,
In most of the patterns, the space in the upper half increases and then the reverse of that is followed in the lower half i.e. decrease in this case.
The no. of spaces in a particular row share a relationship with the previous row.
Let’s consider your code Hollow diamond pattern:
There are a few mistakes in that:
Hope, this would help.