Skip to main content

Skrome

User since Oct 28, 2022
2 Posts
Python

Recent Posts

Caesar Encryption

0 likes • Mar 10, 2021 • 0 views
Python
import string
def caesar(text, shift, alphabets):
def shift_alphabet(alphabet):
return alphabet[shift:] + alphabet[:shift]
shifted_alphabets = tuple(map(shift_alphabet, alphabets))
final_alphabet = "".join(alphabets)
final_shifted_alphabet = "".join(shifted_alphabets)
table = str.maketrans(final_alphabet, final_shifted_alphabet)
return text.translate(table)
plain_text = "Hey Skrome, welcome to CodeCatch"
print(caesar(plain_text, 8, [string.ascii_lowercase, string.ascii_uppercase, string.punctuation]))

Color Gradient

0 likes • Mar 10, 2021 • 0 views
Python
color2 = (60, 74, 172)
color1 = (19, 28, 87)
percent = 1.0
for i in range(101):
resultRed = round(color1[0] + percent * (color2[0] - color1[0]))
resultGreen = round(color1[1] + percent * (color2[1] - color1[1]))
resultBlue = round(color1[2] + percent * (color2[2] - color1[2]))
print((resultRed, resultGreen, resultBlue))
percent -= 0.01

Post Statistics

Posts

No Posts Found

It looks like Skrome hasn't uploaded a post yet

Likes

Please Log In

You must be authenticated to view a user's likes

Shared

Please Log In

You must be authenticated to view a user's shared posts

Profile Privacy

Multi-Factor Authentication

Multi-Factor Authentication (MFA) is an authentication method that requires you to provide two or more verification factors to gain access to your account. In addition to username and password, MFA requires you to verify your email on every login, which decreases the likelihood of someone stealing your account.

Change Password

Forgot Password?

Identity Color

Changes the color of your profile icon and cursor highlight in the live code editor. You and other users will be able to view this change.

Delete Account

Deleting your account is permanent. All data associated with your account will be lost.