Aside

def encrypt(x,n):
c=”
t=len(x)
for i in range(0,t):
if x[i]==’ ‘:
ct=’ ‘
else :
p=ord(x[i])+n
ct=chr(p)
c=c+ct
return c

def decrypt(x,n):
p=”
t=len(x)
for i in range(0,t):
if x[i]==’ ‘:
pt=’ ‘
else :
c=ord(x[i])-n
pt=chr(c)
p=p+pt
return p

Penjelasan selengkapnya ada di Channel Youtube saya
Skip to toolbar