From 32f35f5595e4fa0c02a9240b912bb3adc74f7198 Mon Sep 17 00:00:00 2001 From: Nitya Prakash <43900148+nityaprakash10@users.noreply.github.com> Date: Mon, 11 Oct 2021 21:33:56 +0530 Subject: [PATCH] Create caesarcipher.c --- cipher/caesarcipher.c | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 cipher/caesarcipher.c diff --git a/cipher/caesarcipher.c b/cipher/caesarcipher.c new file mode 100644 index 0000000..66bd5fa --- /dev/null +++ b/cipher/caesarcipher.c @@ -0,0 +1,38 @@ +using System; +using System.Text; + +public class CaesarCipher +{ + // Encrypts text using a shift od s + public static StringBuilder encrypt(String text, int s) + { + StringBuilder result= new StringBuilder(); + + for (int i=0; i