gui almost finish
This commit is contained in:
Executable
+27
@@ -0,0 +1,27 @@
|
||||
try:
|
||||
type_work = input('select type: \n\t1.(encodin)\n\t2.(decoding)\n(1/2) : ')
|
||||
if type_work == '1':
|
||||
path = input('path : ')
|
||||
l = []
|
||||
with open(path, 'rb') as f:
|
||||
info = f.read()
|
||||
print(info)
|
||||
l = [i + 18 for i in info]
|
||||
# print(l)
|
||||
# l = [i - 18 for i in l]
|
||||
# print(bytes(l))
|
||||
with open('encoding_bin.bin', 'wb') as f:
|
||||
f.write(bytes(l))
|
||||
print('encoding sucsses.')
|
||||
if type_work == '2':
|
||||
path = input('path : ')
|
||||
l = []
|
||||
with open(path, 'rb') as f:
|
||||
info = f.read()
|
||||
l = [i - 18 for i in info]
|
||||
with open('decoding_bin.bin', 'wb') as f:
|
||||
f.write(bytes(l))
|
||||
print('encoding sucsses.')
|
||||
|
||||
except:
|
||||
print('error')
|
||||
Reference in New Issue
Block a user