# Vigenère cipher

**URL:** https://discourse.julialang.org/t/vigenere-cipher/69692
**Category:** General Usage
**Tags:** cryptography
**Created:** [October 13, 2021, 3:28pm UTC](https://discourse.julialang.org/t/vigenere-cipher/69692 "2021-10-13T15:28:52Z")
**Posts on this page:** 1
**Showing post:** 4

<div class="post-metadata">

### Author: ![rafael.guerra](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/rafael.guerra/32/216610_2.png) [@rafael.guerra](https://discourse.julialang.org/u/rafael.guerra)
#### Post date: [October 13, 2021, 7:20pm UTC](https://discourse.julialang.org/t/vigenere-cipher/69692/4 "2021-10-13T19:20:37Z")

</div>

From [this post](https://discourse.julialang.org/t/check-for-letters-only-string/41091/9), one could also clean the non-alphabetic characters in the input `message` as follows:

```julia
join([c for c in message if 'a' <= c <= 'z' || 'A' <= c <= 'Z'])

```

_ **NB:** updated the encrypt function above with half of that because added it after uppercasing._

---

_[View the full topic](https://discourse.julialang.org/t/vigenere-cipher/69692)._
