Home
Sign Up
Sign In
推荐学习书目
›
Learn Python the Hard Way
Python Sites
›
PyPI
- Python Package Index
›
http://diveintopython.org/toc/index.html
›
Pocoo
值得关注的项目
›
PyPy
›
Celery
›
Jinja2
›
Read the Docs
›
gevent
›
pyenv
›
virtualenv
›
Stackless Python
›
Beautiful Soup
›
结巴中文分词
›
Green Unicorn
›
Sentry
›
Shovel
›
Pyflakes
›
pytest
Python 编程
›
pep8 Checker
Styles
›
PEP 8
›
Google Python Style Guide
›
Code Style from The Hitchhiker's Guide
V2EX
›
Python
python,数据加密。
JackyXiong
·
JackyXiong
·
Dec 1, 2014
· 3688 views
This topic created in 4365 days ago, the information mentioned may be changed or developed.
如题,在 Python 里怎么对两个字符串进行异或加密?
如 s1='abc', s2='def',php可以直接s1^s2,Python 怎么来加密呢?
加密
字符串
Python
4 replies
•
2014-12-02 10:05:57 +08:00
heqing
Dec 1, 2014
1
[ord(a) ^ ord(b) for a,b in zip(s1,s2)]
hahastudio
Dec 1, 2014
2
https://en.wikipedia.org/wiki/XOR_cipher#Example_implementation
imn1
Dec 1, 2014
3
@
heqing
不用再转回字串/bytes么?
yueyoum
Dec 2, 2014
4
加密这种需求,就别自己实现了。
About
·
Help
·
Advertise
·
Blog
·
API
·
FAQ
·
Privacy
·
Solana
·
4395 Online
Highest 6679
·
Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 45ms ·
UTC 08:19
·
PVG 16:19
·
LAX 00:19
·
JFK 03:19
♥ Do have faith in what you're doing.
❯