te co byly mniej pod reka

This commit is contained in:
acki02 2024-12-06 21:42:54 +01:00
parent 5dafc15833
commit 6027615145
6 changed files with 37 additions and 0 deletions

4
zad_dom3/desktop.ini Normal file
View File

@ -0,0 +1,4 @@
[LocalizedFileNames]
wdi zaddom 3.docx=@wdi zaddom 3.docx,0
diagram b.png=@diagram b.png,0
diagram a.png=@diagram a.png,0

BIN
zad_dom3/diagram a.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 30 KiB

BIN
zad_dom3/diagram b.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

BIN
zad_dom3/wdi zaddom 3.docx Normal file

Binary file not shown.

BIN
zad_dom4/kolory cmyk.docx Normal file

Binary file not shown.

View File

@ -0,0 +1,33 @@
MORSE_CODE_POL_DICT = { 'A':'.-', 'B':'-...',
'C':'-.-.', 'D':'-..', 'E':'.',
'F':'..-.', 'G':'--.', 'H':'....',
'I':'..', 'J':'.---', 'K':'-.-',
'L':'.-..', 'M':'--', 'N':'-.',
'O':'---', 'P':'.--.', 'Q':'--.-',
'R':'.-.', 'S':'...', 'T':'-',
'U':'..-', 'V':'...-', 'W':'.--',
'X':'-..-', 'Y':'-.--', 'Z':'--..',
'1':'.----', '2':'..---', '3':'...--',
'4':'....-', '5':'.....', '6':'-....',
'7':'--...', '8':'---..', '9':'----.',
'0':'-----', ', ':'--..--', '.':'.-.-.-',
'?':'..--..', '/':'-..-.', '-':'-....-',
'(':'-.--.', ')':'-.--.-',
'Ą':'.-.-','Ć':'-.-..','Ę':'..-..',
'Ł':'.-..-','Ń':'--.--','Ó':'---.',
'Ś':'...-...','Ż':'--..-.','Ź':'--..-'
}
def encrypt(message):
cipher = ''
for letter in message:
if letter != ' ':
cipher += MORSE_CODE_POL_DICT[letter.upper()] + ' '
else:
cipher += ' '
return cipher
text = input('Input text: ')
print(encrypt(text))