Биты хранятся в Vector
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
module Main (main) where
|
||||
|
||||
import Codec.Picture
|
||||
import qualified Data.Vector.Unboxed as VU
|
||||
import Lib
|
||||
|
||||
caesarShift :: Int
|
||||
@@ -15,7 +16,7 @@ main = do
|
||||
let encryptedText = encryptCaesar alphabet caesarShift inputText
|
||||
putStrLn $ take 30 encryptedText
|
||||
let encryptedTextBits = textToBits encryptedText
|
||||
putStrLn $ concat (take 30 (map show encryptedTextBits))
|
||||
putStrLn $ concat (take 30 (map show (VU.toList encryptedTextBits)))
|
||||
let encryptedTextFromBits = bitsToText encryptedTextBits
|
||||
putStrLn $ take 30 encryptedTextFromBits
|
||||
let decryptedText = decryptCaesar alphabet caesarShift encryptedTextFromBits
|
||||
|
||||
Reference in New Issue
Block a user