Last active
April 25, 2022 21:08
-
-
Save farach/8d66687c20e6335e34dc45463c903b1b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pandas as pd | |
def pep_talk (): | |
pep_csv = pd.read_csv( | |
"https://raw.githubusercontent.com/farach/pep/main/pep_talk.csv", | |
encoding = 'unicode_escape' | |
) | |
pepText = list( | |
map( | |
lambda x : pep_csv[[x]] | |
.sample(n=1, ignore_index = True) | |
.to_string(index = False, header = False), | |
['p1', 'p2', 'p3', 'p4'] | |
) | |
) | |
print(' '.join(pepText)) | |
pep_talk() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment