#include <stdio.h> int main() { // Caesar encryption , The letters in plaintext are shifted three places to the left or right of the alphabet , Move right here char input[6] = "hello"; char output[6]; int key = 3; int i,j; for (i = 0; i < 5; i++) { int a = input[i]; a += 3; output[i] = (char)a; } output[i] = '\0'; printf(" After encryption :%s\n", output); for (j = 0; j < 5; j++) { int b = output[j]; b -= 3; input[j] = (char)b; } input[j] = '\0'; printf(" After decryption :%s", input); return 0; }
当前位置:网站首页>Implementation of Caesar cipher
Implementation of Caesar cipher
2020-11-07 20:19:00 【PamShao】
版权声明
本文为[PamShao]所创,转载请带上原文链接,感谢
边栏推荐
- 9. Routingmesh service communication between clusters
- In the age of screen reading, we suffer from attention deficit syndrome
- 动态规划——用二进制表示集合的状态压缩DP
- 分享几个我日常使用的VS Code插件
- Don't treat exceptions as business logic, which you can't afford
- 聊聊Go代码覆盖率技术与最佳实践
- 技术债务是对业务功能缺乏真正的理解 -daverupert.com
- vscode 配置
- Exception calling 'downloadstring' with '1' arguments: 'operation timed out'
- Application and principle of handlermethodargumentresolver
猜你喜欢
快進來!花幾分鐘看一下 ReentrantReadWriteLock 的原理!
In simple terms, the large front-end framework angular6 practical course (angular6 node.js 、keystonejs、
Using rabbitmq to implement distributed transaction
Web API系列(三)统一异常处理
【涂鸦物联网足迹】物联网主流通信方式
使用LWA和Lync模拟外部测试无边缘单前端环境
聊聊Go代码覆盖率技术与最佳实践
带你深入了解 GitLab CI/CD 原理及流程
滴滴的分布式ID生成器(Tinyid),好用的一批
Exclusive interview with Yue Caibo
随机推荐
建议患者自杀,OpenAI警告:GPT-3用于医疗目的风险太高
11. Service update
Business facade and business rule
低代码 vs 模型驱动,它们之间到底是什么关系?
廬山真面目之二微服務架構NGINX版本實現
DOM节点操作
Come on in! Take a few minutes to see how reentrantreadwritelock works!
留给快手的时间不多了
Bgfx compilation tutorial
DOM节点操作
The most hard core of the whole network explains the computer startup process
Web API系列(三)统一异常处理
傲視Kubernetes(一):Kubernetes簡介
HMS Core推送服务,助力电商App开展精细化运营
从技术谈到管理,把系统优化的技术用到企业管理
Kylin on Kubernetes 在 eBay 的实践
把 4个消息队列都拉到一个群里后,他们吵起来了
Blazor 準備好為企業服務了嗎?
盘点那些争议最大的编程观点,你是什么看法呢?
栈-括号的匹配