Skip to content

Commit

Permalink
DEF2 Completed :)
Browse files Browse the repository at this point in the history
  • Loading branch information
sahilahmed24 committed Nov 10, 2021
1 parent 4f90a76 commit 7858c63
Showing 1 changed file with 32 additions and 32 deletions.
64 changes: 32 additions & 32 deletions character_map/2.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,48 +4,48 @@

char_input=input("Enter a character: ")

array_D = [[1,1,1," "," "],
[1," "," ",1," "],
[1," "," "," ",1],
[1," "," "," ",1],
[1," "," "," ",1],
[1," "," ",1," "],
[1,1,1," "," "]]
array_D = [[1,1,1,0,0],
[1,0,0,1,0],
[1,0,0,0,1],
[1,0,0,0,1],
[1,0,0,0,1],
[1,0,0,1,0],
[1,1,1,0,0]]

#[" "]==" "; off LED
#[0]==0; off LED
#[1]==1; on LED

array_E = [[1,1,1,1,1],
[1," "," "," "," ",],
[1," "," "," "," ",],
[1,0,0,0,0,],
[1,0,0,0,0,],
[1,1,1,1,1,],
[1," "," "," "," ",],
[1," "," "," "," ",],
[1,0,0,0,0,],
[1,0,0,0,0,],
[1,1,1,1,1,]]

#[" "]==" "; off LED
#[0]==0; off LED
#[1]==1; on LED

array_F = [[1,1,1,1,1],
[1," "," "," "," ",],
[1," "," "," "," ",],
[1,0,0,0,0,],
[1,0,0,0,0,],
[1,1,1,1,1,],
[1," "," "," "," ",],
[1," "," "," "," ",],
[1," "," "," "," ",]]
[1,0,0,0,0,],
[1,0,0,0,0,],
[1,0,0,0,0,]]

#[" "]==" "; off LED
#[0]==0; off LED
#[1]==1; on LED

array_2 = [[" ",1,1,1," "],
[1," "," "," ",1],
[" "," "," ",1," "],
[" "," ",1," "," "],
[" ",1," "," "," "],
[1," "," "," "," "],
array_2 = [[0,1,1,1,0],
[1,0,0,0,1],
[0,0,0,1,0],
[0,0,1,0,0],
[0,1,0,0,0],
[1,0,0,0,0],
[1,1,1,1,1]]

#[" "]==" "; off LED
#[0]==0; off LED
#[1]==1; on LED

array_continue = [[0,0,0,0,0],
Expand All @@ -58,21 +58,21 @@



#[" "]==" "; off LED
#[0]==0; off LED
#[1]==1; on LED

for i in range(7):
for j in range(5):
if char_input == "D":
print(array_D[i][j], end=" ")
print(array_D[i][j], end=0)
elif char_input == "E":
print(array_E[i][j], end=" ")
print(array_E[i][j], end=0)
elif char_input == "F":
print(array_F[i][j], end=" ")
print(array_F[i][j], end=0)
elif char_input == "2":
print(array_2[i][j], end=" ")
print(array_2[i][j], end=0)
else:
print(array_continue[i][j], end=" ")
print(array_continue[i][j], end=0)
print()

#by- sahilahmed

0 comments on commit 7858c63

Please sign in to comment.