In cryptography, you could often break the algorithm if you
know what was the original (plain) text that was encoded
into the current ciphertext. This is called the plain text
attack. In this simple problem, we illustrate the plain
text attack on a simple substitution cipher encryption,
where you know each letter has been substituted with a
different letter from the alphabet but you don’t know what
that letter is.

You are given the cipherText as the input string to the
function getwordSets(). You know that a plain
text "AMMUNITION" occurs somewhere in this cipher text.
Now, you have to find out which sets of characters
corresponds to the encrypted form of the "AMMUNITION". You
can assume that the encryption follows simple substitution
only. [Hint: You could use the pattern in the "AMMUNITION"
like MM occurring twice together to identify this]


No Answer is Posted For this Question
Be the First to Post Answer

Post New Answer

More C Interview Questions

What is output of the following program ? main() { i = 1; printf("%d %d %d\n",i,i++,i++); }

9 Answers   CTS, Wipro,


i want to switch my career from quailty assurance engineering to development kindly guide me from which programming language its better for me to start plz refer some courses or certifications too i have an experience of 1.5 yrs in QA field.Kindly guide me

0 Answers   Microsoft,


How do you initialize pointer variables?

0 Answers  


Explain about the constants which help in debugging?

0 Answers  


Tell me what are bitwise shift operators?

0 Answers  






to write a program, that finds the minimum total number of shelves, including the initial one, required for this loading process. The packets are named A, B, C, D, E …….. Any numbers of packets with these names could be kept in the shelf, as in this example: [ZZLLAAJKRDFDDUUGGYFYYKK]. All packets are to be loaded on cars. The cars are lined in order, so that the packets could be loaded on them. The cars are also named [A, B, C, D, E,………….].

2 Answers   Infosys, TCS,


write a c program in such a way that if we enter the today date the output should be next day's date.

0 Answers  


which type of question asked from c / c++ in interview.

2 Answers  


main() { int i; printf("%d",i^i); }

1 Answers  


wat is output of the following int main() { const int j=2; int i; switch(i) { case 1:break; case j:break; default:break; } }

2 Answers  


What is line in c preprocessor?

0 Answers  


What is auto keyword in c?

0 Answers  


Categories