changeset 0:d0fbe0f50dfb

finished program supposedly
author VilyaemKenyaz
date Sun, 13 Aug 2023 15:38:47 -0400
parents
children ba8447ba5f5c
files asciicaesar asciicaesar.c c.ksh
diffstat 3 files changed, 22 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
Binary file asciicaesar has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/asciicaesar.c	Sun Aug 13 15:38:47 2023 -0400
@@ -0,0 +1,16 @@
+// Encryption and Decryption Program
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
+void main(int argc, char*argv[]){
+char *string = argv[1];
+int modifier = atoi(argv[2]);
+char newchar;
+for(int i = 0;i != strlen(string);i++){
+newchar = string[i] + modifier;
+printf("%c",newchar);
+}
+exit(0);
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/c.ksh	Sun Aug 13 15:38:47 2023 -0400
@@ -0,0 +1,6 @@
+#!/bin/ksh
+clear
+printf "Compiling\n"
+rm asciicaesar
+gcc asciicaesar.c -o asciicaesar
+cp asciicaesar /usr/bin/