Python Program:

- To print alphabet A pattern using *

Example:

User Input: 3

Output:

    *
  * * *
*       *
rows=int(input("Enter number of rows : "))
for i in range(rows,0,-1):
  for j in range(1,2*rows-i+1):
    if(j==i or j==(2*rows-i) or (j>i and i==int(rows/2)+rows%2)):
      print("* ", end="")
    else:
      print("  ", end="")
  print("")

Output:

Enter number of rows: 5

        *
      *   *
    * * * * *
  *           *
*               *
Program
pattern

Main Logic :

for i in range(rows,0,-1): #rows : number of rows to print
  for j in range(1,2*rows-i+1):
    if(j==i or j==(2*rows-i) or (j>i and i==int(rows/2)+rows%2)):
      print("* ", end="")
    else:
      print("  ", end="")
  print("")

You can print any thing in this pattern, just replace your value with *

Concept

Coming Soon !

Quick
Tutorial

Quote

In order to carry a positive action, we must develop here a positive vision.