0% found this document useful (0 votes)
10 views

Caser Chiper

Uploaded by

Aatika
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views

Caser Chiper

Uploaded by

Aatika
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 12

Caesar cipher

Algorithm and
implementation
What ?
 The Caesar Cipher is one of
the simplest and oldest
methods of encrypting
messages, named after Julius
Caesar, who reportedly used
it to protect his military
communications.
Technique

 This technique involves


shifting the letters of the
alphabet by a fixed number of
places. For example, with a
shift of three, the letter ‘A’
becomes ‘D’, ‘B’ becomes ‘E’,
and so on.
Example
Example (Encryption)

Here is an example of how to use the Caesar cipher to


encrypt the message “HELLO” with a shift of 3:
 Write down the plaintext message: HELLO
 Choose a shift value. In this case, we will use a shift of
3.
 Replace each letter in the plaintext message with the
letter that is three positions to the right in the alphabet.
 H becomes K (shift 3 from H)
E becomes H (shift 3 from E)
L becomes O (shift 3 from L)
L becomes O (shift 3 from L)
O becomes R (shift 3 from O)

Example (Decryption)

 To decrypt the message, you


simply need to shift each letter
back by the same number of
positions. In this case, you would
shift each letter in “KHOOR” back
by 3 positions to get the original
message, “HELLO”.
Formula (Encryption)
Formula (Decryption)
Algorithm
 Input:
 Choose a shift value between 1 and 25.
 Write down the alphabet in order from A to Z.
 Create a new alphabet by shifting each letter of the
original alphabet by the shift value. For example, if the
shift value is 3, the new alphabet would be:
ABCDEFGHIJKLMNOPQRSTUVWXYZ
DEFGHIJKLMNOPQRSTUVWXYZABC
 Replace each letter of the message with the
corresponding letter from the new alphabet. For
example, if the shift value is 3, the word “hello” would
become “khoor”.
 To decrypt the message, shift each letter back by the
same amount. For example, if the shift value is 3, the
encrypted message “khoor” would become “hello”.
Code (Encryption)
Code (Decryption)
Code (Main)

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy