I have seen all of the following notations used to denote the encryption of a message $m$ with the key $k$ to produce the ciphertext $c$:

  1. $c = E(k,m)$

  2. $c \leftarrow E(k,m)$

  3. $c := E(k,m)$

Is there any difference between them?

  • 11
    $\begingroup$ This needs a ton more context, so you should edit your question to clarify where you're encountering these notations. But I'm going to bravely guess that C = E(K, m) is an equation (a mathematical statement that the two expressions have the same value), while C := E(K, m) and C <- E(K, m) are assignment statements (in a programming (pseudo)language with mutable variables). Whether the last two are synonymous or different may depend on context—sometimes the back arrow syntax is used for "special" assignments, like probabilistic ones instead of deterministic. $\endgroup$ Commented Sep 16, 2016 at 4:06
  • 11
    $\begingroup$ Depending on context, (1) could also mean assignment. $\endgroup$
    – poncho
    Commented Sep 16, 2016 at 4:11
  • 3
    $\begingroup$ One fairly common convention is to read $:=$ as "is defined as" or "equals by definition". That is, $C := E(K,m)$ explicitly introduces a new (constant) symbol $C$, as opposed to asserting a claim about some (possibly) previously defined $C$. $\endgroup$ Commented Sep 17, 2016 at 20:44
  • 2
    $\begingroup$ If there's some specific book or article where these notations are confusing you, it would still be nice to know which one it is so that we could tell what that specific author is using them for. But other than that, I think your question looks basically answerable, at least as well as it has already been answered in the comments above. Voting to reopen. $\endgroup$ Commented Sep 18, 2016 at 10:31
  • $\begingroup$ This question is similar to crypto.stackexchange.com/questions/34799/… $\endgroup$
    – Carl Knox
    Commented Feb 7, 2017 at 15:17


Browse other questions tagged or ask your own question.