Tumgik
coding-recap · 1 year
Text
FUCKING EXAMM
SO ITO NA ANTEH MAY EXAM NA PLEASE LANG ARAL NA EMSSS
0 notes
coding-recap · 1 year
Text
15/100 days of productivity (coding)
MAY 15, 2023
Well nagyon lang me nakapag aral ng 2hrs coding, and It’s PANDA by Keith. So I understand how to read a csv sa python by pd.read_csv, and to save the .to_csv. To ADD a column: df[’EME’] = 1
then how to read the header/columns by using df.columns to read row df.iloc[index] ------------ you can also use df.iloc to get the specific item ex df.ilov[row=2, col=1] = Venusaur Then meron din df.loc where you can use it for conditional changes or filtering the data.  ex: df.loc[(df['Attack'] >= 100) & (df['HP'] >=100)] = kung sino may highest 100 pwede din to df.loc[df.loc[df['Name'].str.contains('Mega')] kung sino may name na MEGA and you can put ~ sa pinakauna to know kung sino naman walang MEGA  You can also modify the data by doing this ex: df.loc[df['Type 1'] == 'Fire', 'Type 1']='Flamer' = where in index/column that has fire will be modified to flamer df.loc[df['Total'] > 500, ['Generation', 'Legendary']]= 'Test Value'= you can also imput column/header you want to changee as long ipupust mo sa [LIST]
Pwede din na sort or arrange it to what ever you want ex: df.sort_values(['Name', 'HP'], ascending(low to up)=[1= TRUE,0=FALSE]) To rearrange kailangan mo mmuna idefine si col:
cols = list(df.columns.values) = mga values na nasa columns df = df[cols[0:10] + [cols[-1]] +cols[10:12]] Then pwede mo din malaman yung mga stats ng data by  dt.describe() Overall keribells lang nakakalito ng konti but atleast I learned sum ALSO REMEMBEER TANGANG TO USE BAR BRACES [INDEX] FOR INDEX LAGING PARENTHESIS() EH  NOTE sabi ni Keith checck dibn ang Pandas user guide eme
0 notes
coding-recap · 1 year
Text
14/100 days of productivity (coding)
MAY 12, 2023
So i study 2hrs python ulit using datacamp, and sheesh late pa me nagsimula, daming mga household chores emeee so natapos ko yung sa numpy don sa datacamp, which is yung 2d np array. and sheesh ang galing tehhh.
RECAP: impor numpy as np (thats why np linalagay ko) 2D NUMPY ARRAY: np.array(var[row][col]) - same with 1d pwede  mo din islice and index eme
-and also para malaman mo kkung ilan yung columns you can use: np.shape(var) along with the topic I also learned na pwede ka din gumamit ng stats formula sa numpy: mean: np.mean(var[][]) - average median: np.media(var) - pinakagitna sa list standard dev: np.std(var[][]) correlation: np.corrcoef(var) i also learned pwede ka din maground off using the np.round(var, exp) you can also generate your own random dat by doing this ccode: np.random.normal(1.75, .20, 5)
and if gustong mong ipagsama ang dalwang random data this is the code: np.column_stack((np_h, np_w))
0 notes
coding-recap · 1 year
Text
13/100 days of productivity (coding)
MAY 11, 2023 (Thurs)
Hallu hallu hallu (ref) so ayon nagral ulit me ng python 2hrs study siya anteh, or more so. so gumamit me ng datacamp ansd magadan sezzss, easy to gets naman for beginner talaga.
1. natutunan ko yung sa index slicing var[kasama si START: di kasama si END: STEPS], si index yung pang ilan sa sa string or list
2. I also learned yung sa mga ibat ibang functions, gaya ng .count, .replace etc... JUST REM: var.method
3. I ALSO LEARNED NUMPY BITCH IT IS A NUMBERICAL PYTHON
note: dapat di same ang file name mo sa module, para di mabobo si python. BOBO KA NA NGA, IPAPABOBO MO PA SI PYTHON DIBA, EDI LAHAT BOBO NA!
4. sa Numpy pwede mong icalculate yung mga nasa list ng mabilisan, na hindi kaya ng python list. need mo lang iconvert ang python list sa numpy array using np.array(var). np kasi pinaikli mo yung numpy as np.
5. more on calculation in array yung sa numpy so keri keri boom. Then pwede mo din malamaan yung boolean as nlong may conditional 
ex : np_light =(np_weight < 20) 
OUTPUT: TRUE OR FALSE
6. Then para makuha mo yung data ng boolean, like para malaman mo kung sino nagTRUE don sa conditions mo print this
ex print(np_weight[np_light]) remember dapat nasa loob yung pinagboolean mo teh [index] kasi to, na kung saan nakaplace ang isang VALUE
7. also pwede mo din maget ang index ng isang weight, by using this
ex: print(np_weight[50]) para makuha mo yung value na nasa index 50
pwede din to: print(np_weight[50:100]) para makuha mo yung value ng index from 50 to 100
OVERALL okay okay pa naman, pero nalilito me sa ibang part. Neverthless big step na ito. sabi nga ni TIna Huang “ Just learning enough, moving on and iterating(repeating)”
0 notes
coding-recap · 1 year
Text
12/100 days of productivity (coding)
MAY 20, 2023
Another day and another coding. so the project I did is the Dice roller game and it is user vs comp, so nice nice~
DICE ROLLER GAME 
1. First initiaize ko mmuna yung dice art and 6 dice yon, then pinagsamasam ko silang lahat as a list sa loob na variable na game art
2. Ofcourse title of the game, then kapag piindot mo yung ‘r’ magrarandomize na yung two dice kung ng no. from 1 to 6. and may countdown from 1 to 3 secs bago ilabas kung ano yung dice mo, para di naman nakakshokla.
3. kapag prinint na yung dice mo dun din lalaba yung gameart and nakaindex siya sa kung anong number lumabas sa dice random mo.
4. Same thing happen sa computer, but this time may 5 seconds leght bago ilabas yung dice ni comp.
5. May scoring systerm din para din para alam mo kung ilan yung score mo and ni user.
6. Another thing, kapag nagdradraw siya, same with the rock, paper, scissor game, nagau-automatic siyang nag roll, ofcourse you still have to press ‘r’ for simulation eme (HAHHAHAH SABI YAN NG TEACHER NAMIN, NEED DAW YAN EME NIYA!)
7. ang pwede ka din maglaro hanggang magsawa ka, since dun ka magaling. Eme, mag hugot yarn? basta yon!
8. Also narealize ko lang pwede mo palang gawing underline and bold yung print text mo. LIKEE SHEESSH SO GALING!!. 
ito yung code (from stackoverflow): print("\033[1mYOU LOSE!\033[0m")
then ito yung output:  YOU LOSE!
diba ang galing! sheesh flexy yarn?
overall yun na tapos na me, nxt gusto ko gumawa ng program don related sa shop namin na si python nalang magcocompute at para di nadin need magsearch kung magkkano ba yung product ganern!
source  code: https://github.com/elaismith/Python/blob/main/DiceRoller.py
0 notes
coding-recap · 1 year
Text
11/100 days of productivity (coding)
MAY 9, 2023
So i fill like I’m in a tutorial hell, and to escape daw yon, gumawa daw ng prorjects without watching some videos ganon. Like create your own personal project. And I did bading!!! NAKAKAPROUD DIN NO. ofcourse bnagsearch ako jay google like anop ibig sabihin nito and ganyan, like what is the fuction of this. Pero I finish it!!!. 
ITS A CALCULATOR:
1. Meron siyang question if gusto mong irun yubng program or not, and if not may shushut down na siya agad
2. Linagyan ko din ng time, like 3 secs before gumana na yung prog #maarteAko. And linagyan ko din ng konting design
3. So mag iinsert ka nung 1st number. and after operator na, kapag wala sa choice yung opeator na linagay mo, uulit siya ng uulit, until maging tama
4. naka cases yung bawat operators para madaing maintindihan at hindi puro ELSEIF kakaloka! 
5. ex case1: magiinput muna si user 2nd num, and after no may condi statement, if yung 1st num>0 nilagay edi isososlve yung sa total, else yung total magoop don sa 2nd num
6. bibigyan ng choices si user kung gusto niyang pang iadd up yung sa total is yes yung 1st num ay = 0, para else condition yun ifofollow sa case system
7. Iiask ulit kung gusto ulitin hung buong program, where back to zero lahat.
8. if no lianagay ni use magshushutdown lahat. and same sa una may time loop din, pero 5 secs. ginamitan ko pala to ng for loop.
9. AFTER THAT PROGRAM IS SHUT DOWN!!
source code:  https://github.com/elaismith/Python/blob/main/CACULATO.py
0 notes
coding-recap · 1 year
Text
10/100 days of productivity (coding)
MAY 8, 2023
So its my 10th day, kasi nag dopamine detox aketch so yah. Ayon nag aral ulit me ng python, pinagaralan ko yung create, read, copy file shocks galing teh. tapos nagstudy me ng konting automation. I also known na how to install llib/packages sa python so its good good don. need ko sigurong ifurther yung knowledge ko with pandas muna
0 notes
coding-recap · 1 year
Text
9/100 days of productivity (coding)
MAY 6, 2023
NOT EXACTLY 2HRS WORTH STUDYING PYTHON.
But i did a simple project called random pass generator using string and random. I just use .append on string kasi nga string(string.digits, string.punctuation, string.ascii_letters) sila and si gagana yung arith ops.tapos pwedeng aginsert yung user kung ilang number or letter ang gusto niyang included don sa password.
Also for every char in range(1,l+1):            rpass,append(random.choice())
for every char in rpass:
         pass += char
return pass
Tumblr media
i also use function para mapractice ako, basta ayun na yon
source code: https://github.com/elaismith/Python/blob/main/random%20pass%20gen.py
0 notes
coding-recap · 1 year
Text
8/100 days of productivity (coding)
MAY 5, 2023 YIE FINISH 1 WEEK STUDYUING CODING NICE NICE
I just finish 2hrs studying PYTHON BITCHH!! so natapos ko yung: 
FUCTION:
def function()- meron din defARG and keyARG, and meron din *args and **kwargs, ginagamit lang tong dalawa kapag gusto mog imput ng many arguement dahil isa kang palaban na tao, eme
BUILT IN MODULE: 
you put import module, or from module import (anything nasa loob ng module)     also pwede mo din gawin import module as m para mas madali ang typing 
ex import math as m    print(m.pi)
SCOPE:
I also finish scoping of value nagstatart sa LOCAL-ENCLOSED-GLOBAL-BUILT IN (LEGB)
I also did a project called encrypt and decrypt: where you put a text to encrypt 
Source code: https://github.com/elaismith/Python/blob/main/encryption%20program.py
0 notes
coding-recap · 1 year
Text
7/100 days of productivity (coding)
MAY 4, 2023
Dapat yesterday yung day 7, kaso may brace adjustment me, and so uncomfortable teh kaya ayon di muna ako nagaral magcode. PERO TODAYY GUMAWA ME NG PROJECT, ROCK, PAPER, SCISSOR PYTHON emee. meron siyang game art kinuha ko lang sa isang site HAHAHAH, pero may twinitch and binago ako don para mas mukhang maganda and more efficient. like kapag nagdradraw automatic na magrurun ulit yung game. and ayon may pointing system din para malaman mo kung ilan points mo and talo ka ba or not
I also import random and use random.randint para mas madali kaysa itytype pa. katamad HAHHAHHAA
Tumblr media
Source code: https://github.com/elaismith/Python/blob/main/RockPaperScissor.py
0 notes
coding-recap · 1 year
Text
6/100 days of productivity (coding)
MAY 2, 2023
So late me ulit nagstart mag aral pero nacommit ko namna yung 2 hrs! napagaralan ko yung random module and nakagawa me ng game which is guess game so niceee~~
Source code: https://github.com/elaismith/Python/blob/main/DecisionMaker.py
0 notes
coding-recap · 1 year
Text
5/100 days of productivity (coding)
MAY 1, 2023
So nalate me nagising, pero nacommit ko naman yung 2hrs study code. Unulit ko yung ibang vids ni bro code yung mga bago about sa python, and I learned alot! (eme plastic) I did some exercises and may ginawa din me na project yung counter clock with seconds. Where the use will input a seconds tapos mag cocount down yung program. it uses import time with the method of time.sleep(1) para malaman kung ilan sec ba magcocount down before sa another sec, basta yon
Tumblr media
Source code: https://github.com/elaismith/Python/blob/main/counterclock.py
0 notes
coding-recap · 1 year
Text
4/100 days of productivity (coding)
APRIL 30, 2023
it’s not 2hrs study to be honest but I created a project called drag name generator. Where I have a list of drag fn and ln and it randomly chooses like mix match ganon
Tumblr media
Source code: https://github.com/elaismith/Python/blob/main/Drag_name.py
0 notes
coding-recap · 1 year
Text
3/100 days of productivity (coding)
Well, well, well, dapat kahapon ako magaaral kaso umalis me para kumuha ng doc sa school kaya ayon ngayon me nagaaral. Ang ginawa ko today is gumawa ng project sa coding using python, and ang ginawa ko is otome game. Basta love life romance game ganon #LFJOWA. HAHHAHAHAHAH. So ang name is LOVE LINE, and ang plot non is nasa party ka and may nagapproach sayong guy, so anong gagawin mo? Play the game to find out. Eme. pwede ka maginsert ng name ng Significant other mo don so yeah, and pwede din umulit.
Tumblr media
#LOVELINE
sourcecode: https://github.com/elaismith/Python/blob/main/otome_game.py
0 notes
coding-recap · 1 year
Text
2/100 days of productivity (coding)
Another day, another coding eme... Ayon nag aral ulit me sa mga videos, napagaralan ko yung list, 2d list, tuple, set, dictionary. Shala naman si python daming learn. Overall keri pa naman. Naghahanap din me ng projects na pwedeng gawin para mas lalaong mahone yung skills ko. thats all kemerut #2hrs coding na tinatamad na ako teh
0 notes
coding-recap · 1 year
Text
1/100 days of productivity (coding)
So basically 3rd day ko sa pag aaral ng python even though nagstart ako dati pa, pero well tamadera si accla kaya yorn. I just spent 2 hours of coding, nice start naman, and I learned alot!
I did a project which is mario from cs50, and thankfully I got it! nauunderstand ko nanaman yung mga ibang stuff and also loop too, pero naooverwhelm lang ako sa dami ng functions and prompt. pero this is still a big step to me. 
Tumblr media
 and this is the source code: https://github.com/elaismith/Python/blob/main/forloopproj1.py
STUDY CS50 NALANG TEH AND NICE JOB, TULOY TULOY MO LANG ANTEH
0 notes
coding-recap · 1 year
Text
PYTHON PROJ 1: Discount Calcu
So this is my first ever project in learning Python. 
Tumblr media
So if PWD ka or Senior may discounted price ka, yun lang yon HAHAHAH. siguro after nito gusto ko pa siya pabonggahin. 
https://github.com/elaismith/Python/blob/main/Project1_Cashier.py
0 notes