0
0
Intro to Computingfundamentals~20 mins

Encryption basics in Intro to Computing - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Encryption Expert
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
2:00remaining
What is the main purpose of encryption?

Encryption is a process used in computing and communication. What is its main purpose?

ATo delete data permanently from a device
BTo convert readable data into a secret code to protect it from unauthorized access
CTo compress data so it takes less space on the disk
DTo speed up the transmission of data over the internet
Attempts:
2 left
💡 Hint

Think about why secret messages are used in spy movies.

trace
intermediate
2:00remaining
Trace the output of a simple Caesar cipher

Given the text 'HELLO' and a Caesar cipher that shifts letters by 3 places forward, what is the encrypted output?

Intro to Computing
def caesar_encrypt(text, shift):
    result = ''
    for char in text:
        if char.isalpha():
            shifted = chr((ord(char) - 65 + shift) % 26 + 65)
            result += shifted
        else:
            result += char
    return result

print(caesar_encrypt('HELLO', 3))
AIFMMP
BEBIIL
CHELLO
DKHOOR
Attempts:
2 left
💡 Hint

Each letter moves 3 places forward in the alphabet. 'H' becomes 'K'.

identification
advanced
2:00remaining
Identify the type of encryption used

Which type of encryption uses the same key for both encrypting and decrypting data?

ASteganography
BAsymmetric encryption
CSymmetric encryption
DHashing
Attempts:
2 left
💡 Hint

Think about a single key that locks and unlocks a door.

Comparison
advanced
2:00remaining
Compare encryption and hashing

Which statement correctly compares encryption and hashing?

AEncryption is reversible with a key; hashing is one-way and not reversible
BBoth encryption and hashing are reversible processes
CHashing requires a key to reverse; encryption does not
DEncryption and hashing both produce the same output for the same input
Attempts:
2 left
💡 Hint

Think about whether you can get the original message back.

🚀 Application
expert
2:00remaining
Determine the output length of encrypted data

A message of 128 bytes is encrypted using AES with a block size of 16 bytes. What is the length of the encrypted output in bytes?

A128 bytes
B144 bytes
C256 bytes
D16 bytes
Attempts:
2 left
💡 Hint

AES encrypts data in fixed-size blocks. If input fits exactly, output size matches input size.