Substitution Cipher (Java)

import java.util.*;
class SubCipher
public static void main(String args[])
Scanner sc=new Scanner(;
System.out.println(“Enter the plain text”);
String pl=sc.nextLine();
System.out.println(“Enter the shift factor”);
int n=sc.nextInt();
System.out.println(“Cipher Text:”);
char a[]= pl.toCharArray();
for(int i=0;i<a.length;i++)
for(int i=0;i<a.length;i++)

One thought on “Substitution Cipher (Java)

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.