我在大学的一个项目中工作,他们使用了典型的 Cesar Cipher 之类的问题。它更像是一个函数式程序,需要尽可能地是最基本的。
该程序将从用户那里收到一个数字65
,90
例如当用户插入时65
将显示68
。会添加3
数字,但是当用户给出时90
会给出67
。90+3 ---->90,65,66,67
. 65
这是一个从到的循环90
。
#include <stdio.h>
int cesar_encrypted(int x)
{
return (x+3);
}
void test_cesar_encrypted(void)
{
int x;
scanf("%d", &x);
int z = cesar_encrypted(x);
printf("%s\n", z);
}
int main(){
test_cesar_basic();
}
我做了这个示例代码,但我们只能走得更远,如果你给90
他会给93
我想要67
的。
谁能帮我把它包装在90左右?