#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]所创,转载请带上原文链接,感谢
边栏推荐
- DOM node operation
- awk实现类sql的join操作
- On the coverage technology and best practice of go code
- 模型预测准确率高达94%!利用机器学习完美解决2000亿美元库存难题
- 一文详解微服务架构
- Implementation of nginx version of microservice architecture
- If you want to forget the WiFi network you used to connect to your Mac, try this!
- 使用“1”个参数调用“DownloadString”时发生异常:“操作超时”
- 技术债务是对业务功能缺乏真正的理解 -daverupert.com
- Classroom exercises
猜你喜欢

In simple terms, the large front-end framework angular6 practical course (angular6 node.js 、keystonejs、

AC86U kx上网

Vscode configuration

不懂数据库索引的底层原理?那是因为你心里没点b树

盘点那些争议最大的编程观点,你是什么看法呢?

Win10官方1909版本无法打开windows安全中心中病毒和威胁防护的实时保护解决方案。

Huawei HCIA notes

The official 1909 version of win10 cannot open the real-time protection solution of virus and threat protection in windows security center.

使用LWA和Lync模拟外部测试无边缘单前端环境

HandlerMethodArgumentResolver使用和原理
随机推荐
傲視Kubernetes(一):Kubernetes簡介
使用 Xunit.DependencyInjection 改造测试项目
Code Review Best Practices
Come on in! Take a few minutes to see how reentrantreadwritelock works!
Let you have a deep understanding of gitlab CI / CD principle and process
如何高效的学习技术
当 TiDB 与 Flink 相结合:高效、易用的实时数仓
vscode 配置
是时候结束 BERTology了
使用LWA和Lync模拟外部测试无边缘单前端环境
C语言Ⅰ博客作业03
Kylin on Kubernetes 在 eBay 的实践
不懂数据库索引的底层原理?那是因为你心里没点b树
DOM节点操作
What is the relationship between low code vs model driven?
DOM节点操作
The samesite problem of cross domain cookie of Chrome browser results in abnormal access to iframe embedded pages
Technical debt is a lack of real understanding of business functions- daverupert.com
On hiz buffer
「混合云」会是云计算的下一个战场吗?