We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2bbd7bd commit 093ee18Copy full SHA for 093ee18
Alphabetic Patterns/alphabeticpattern20.py
@@ -0,0 +1,25 @@
1
+def pattern(n):
2
+ alpha = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
3
+ counter = n
4
+ for i in range(n,0,-1):
5
+ counteri = counter-1
6
+ for j in range(0,i):
7
+ print(alpha[counteri],end=" ")
8
+ counteri = counteri+1
9
+ print("")
10
+ counter = counter - 1
11
+
12
+print("Enter the number of rows: ")
13
+n = int(input())
14
+pattern(n)
15
16
17
+# OUTPUT
18
19
+# Enter the number of rows:
20
+# 5
21
+# E F G H I
22
+# D E F G
23
+# C D E
24
+# B C
25
+# A
0 commit comments