This paper considers a new approach to cryptanalysis based on
simulation of behavior of flocks of birds and schools of fish called Particle
Swarm Optimization (PSO). It is shown that such algorithm could be used
to break the key for a simple substitution cipher. This paper presents a
proposed 2-opt PSO algorithm to enhance the efficiency of PSO algorithm
on attacking simple substitution ciphers.