My first code!

--Originally published at codemathblog.wordpress.com

pythonjoke

 

Okey! I did it! It just took my like half hour! hahaha but finally. First I did the typic “Hello world” but i wanted to do more so this is the result of my code:

codeSS

And it’s AWESOME to see something i did from 0, even if it just a simple thing.

I learnt how to ask the person to write something, but the pc gets the data as a string so i investigated how to turn a str into a int and i just have tu put int(And the name of the variable i want to convert). At the end, it was easy, this is the code i made:

codigo

Do you like my theme ;)? it is named “Obsydian”and i did it in the IDLE of Python.

I see now that i can convert the variables when asking for them instead of to write new variables o: something like this:

i will use the age variable as an example:

age=(int(input(“how old are you”))) #This will be an int instead of a str

Okey, I am happy of what i did here! Everyday i will try to do challenges, also i probably will open a Java zone on my blog and do the same stuff with Java and do an analysis between java and python. Maybe html or javascript for the ones who want to personalizate their web page.

Maybe i will open a tutorial zone, it can be on physics, math, python, java, idk, whatever can help my friends to improve,

Thanks for reading! Have a nice day