diff --git a/Groovy/XOREncryption.groovy b/Groovy/XOREncryption.groovy index f422b7b..6f6317c 100644 --- a/Groovy/XOREncryption.groovy +++ b/Groovy/XOREncryption.groovy @@ -3,9 +3,9 @@ def encryptDecrypt(String input) { def output = [] for(int i = 0; i < input.length(); i++) { - int a = input.charAt(i) as int; - int b = (key[i % key.size()] as char) as int - output.add((a ^ b) as char) + int a = input.charAt(i) as int; + int b = (key[i % key.size()] as char) as int + output.add((a ^ b) as char) } output.join("")