Therearejust a fewmorethings I wanttoshowyouguys, Uh, let's goaheadandgetintoit.
Sothefirstthing I wannatalkabouthispackageswithPythonsoyouknowthereasonwhyPython?
It's such a popularlanguageinsuch a powerfullanguage.
Yes, it's easytowrite.
Yes, it's fast, too, right?
Yes, it's easytoreadallthosethings, butthereareotherlanguagesthatmeetthosecriteria, like R andJuliaandRubyandotheronesthat I can't thinkofrightoffthetopofmyhead.
Now, anotherthingthatyoucandioisifyouweregonnaimport a lotoffunctions, youmightuse a wildcardlikethis.
Sothisisjustalmostlike a regularexpressionforeverythingor a wildcardthatjustmeansallthethingsSowecoulddothatandwecanrunthisbutthismakesyourcodeprettyhardtoread.
Firstofall, becausethatsomeone's readingyourcodeand, like, do a thing.
Also, let's sayyou'vegot a lotofscriptsin a thingthatwewouldmorelikelycall a package.
Likeinthiscase, it's just a singlescriptthatwe'regonnaimport.
I wouldn't callthat a libraryor a package.
Well, youwouldcall a packageislike a group, a clusterofscripts.
Solet's make a newfolderand I'm gonnacallit a moddir.
Andthen I'm gonnatakeexamplemodhere, and I'm justgonnaputitintomydirt.
Sothenyoumightalsodosomethinglikethis.
Sofrommoderdotexamplemodimport, do a thingprintorno, wedon't havetoprintthat.
Wejustrun, dosayingboom.
Okay.
Andsothat's howyoucouldhave, like a groupofscriptsinsideof a directoryandreferenceoneofthemspecifically.
Okay, I thinkthatprettymuchcovers.
Ah, themeantheextremebasicsofwhat a moduleis.
It's notthatcomplex.
Inmostcases, it's just a pythonfile.
Insomecases, itdoesget a littlemorecomplexbecauseit's really a pythonwrapperaround C code s soitdoesget a littlemorechallengingandespeciallyhistorically, itwasverychallengingtoworkwithWindowsinthisway.
Butthethingis, you'reyou'replausiblybringingin a lotofcode.
Andthenwhenyouusenumbpiewhenyouimportnumbbywhateverisinlike a mainlubeorarenot a mainloubut a mainfunctiontorunorwhenyouinitializethatthingthatyou'veinstalled, you'repleasantlyrunning a lotofcode.
Andit's in a waythat a firewallislesslikelytocatchbecauseitdoesn't look a suspectasyourunningsomecrazydot e x e file.
Sopayattentionandthinkaboutwhatyou'redoinghere, becausewhenyou'reinstalling a packagefromPip, youaretrustingsomeoneelse's code.
You'rejusttakingitunlessyou'rereadingeveryline, which I knowyou'renotlike.
Youhavetounderstandwhatyou'reactuallydoing.
Andbecauseofthis, I wouldreallywatchoutbecause, like, forexample, reallyrecently, um, let's say a pythonpackagepythonpackage.
Inatleastinthiscase, whattheyweredoingwasanytimeyouentered, like, a Bitcoinaddress, itwouldjustchangeitto a differentBitcoinaddressthatwhoeverwasdoingthis, umandthat's whatthatwasdoing.
Butitcoulddoallkindsofmaliciousthings.
Andsoyoujustneedtobecareful.
So, youknow, checkandrecheckthepackagename, maybegototheofficialpackageonthepythonpackageIndex.
Lookingtosee I don't evenknow.
Usually I don't evenlookhere.
Itwouldbecooliftheysaidhowmanyinstallswereused.
Youalsocouldlookattheirgethubpagelikethisonedoesn't appearto, whichisweird, cause I swear, textrapisn't thatnew, ButwhatwhatsaywewenttoDjango?
Um, lookatDjangotoseeiftheirstatsaregood.
Sohere, youcanseeOkay, ontheirgethope, they'vegotquite a few.
Um, I don't knowwhatitwouldlooklikebefore, buttheotherthingyoucouldalwaysdoisgototheirgethubandjust, youknow, confirmyou'vegotthepackagename, right?
Soitwastype O tobetheEuropeanspelling, I guessofcolorwithyou.
Buttheproperoneispip.
Installcolorrama, andsowecanassaultthatway.
Also, I'm justtryingtogetmyselfintothehabitofalwaysusingthespecificversionsoap I dashthreesevenDashandPipinstallcoloraMMAlikesoandthatwillgiveusthecolorRamapackage.
Nowwhenyouget a newpackage, let's justGooglecolorRama.
There's a varietyofways, um, thatpackageswilldocumentthemselvesandeveryonenoone's documentationsasgoodaseverybodyelse's.
So, um, youjustkindoflikeeveryone's documentations a littledifferent.
I don't knowwhythisisreallycrispandclear, butthattextwasnotletmegoproperties.
It's alreadyquitelarge.
Let's go.
72.
I don't reallywantitthatbig.
We'llgo 36.
Let's useJusttry a differentfault.
Fontover.
Theydidn't screwanythingup, butwe'llfindout.
Okay, Whatever.
So, uh, next I wanttodois, uh, let's addthisnowtoourticktacktoegame, becausethisisallfineanddandy, butlet's actually, like, changesomethinginticktacktoeoractuallyusethepackagebecausedemosarealwaysdifferentthanactuallyusingit, oryoujustdon't realizecertainthings.
Right?
So, uh, what I wanttodoisbopintototrail 14 I think a copypastethatcallthatcallthistutorial.
15.
Now, right, clickitopenupinsuperlame, and I'm gonnaexitoutofthereandlet's gototheActually, firstweneedtobringin, umcoloraMMA.
When I learnedPython, thething I wastryingtolearnwastodosentimentanalysisinnaturallanguageprocessing, likeThat's why I learned a programinthefirstplaceandmostpeoplewouldhavebeenlikeOh, that's a horriblebeginnerproject.
Butforme, itwasperfectbecauseitwaswhat I wasinterestedinactuallydoing, andsobecause I wasexcitedaboutit, itmadelearningPythoneasy.
Andthat's why I thinkbasicsare, youknow, it's importantthatwejustgetoutofthebasicsasfastaspossible.
Isthere a bunchofstuffthat I didnotcoverthatwewouldconsidertobebasicPython?
DefinitelymeanWeleft a lotofstuff, likeevendictionaries.
Wejustbarelygrazedthem, so I feltlikeitwouldbe a sinnottoshowyoudictionaries, butthere's a lotofstuffthatwedidn't cover.
YoucanalsogotothepythonsubredditsoredditdotcomslashorslashpythonThat'lltakeyoutoyouknow, therecentgoingsonsandhappeningsinpythonrightnow s soyoucangetideasonprojects, seewhatotherpeopleareworkingon.
There's alsolearnpythoneyes, anotherone.
Sothere's thatYoucanalsocomeandjointhediscord.
DiscordorgslashCentexwilltakeyoutoaninviteforthesyntaxserver, andyoucanchatwith a bunchofotherpeople.