Code to create Matrix Rain

Start
				
					import time
from os import system, name
import random
# define our clear function 
def clear(): 
    # for windows 
    if name == 'nt': 
        _ = system('cls') 
    # for mac and linux(here, os.name is 'posix') 
    else: 
        _ = system('clear') 
# random characters
chars = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z']
# animation main loop
while True:
    # clear the console
    clear()
    # generate a random string
    string = ''
    for i in range(random.randint(10, 30)):
        string += random.choice(chars)
    # display the string
    print(string)
    # wait for 0.1 second
    time.sleep(0.1)
				
Previous Story

Tracers in the Dark: The Global Hunt for the Crime Lords of Crypto

Next Story

VMWare user? Worried about “ESXi ransomware”? Check your patches now!