January 03, 2009

Study Phyton Programming

Today , I was studied together with my new friends that begin studying phyton programming. It seems so complicated but when I try to learn, it feel so cool, simple and easy. I just try to make a simple program to convert temperature from celcius to reamur, to fahrenheit, and to kelvin. I felt that it is simpler than c++ that I ever learned before. No include modules and so on. Check this out :

C=100
Print “convert to fahrenheit =”, (9/5*C+32)
Print “convert to kelvin=”,(C+273)
Print”convert to reamur=”((4*C)/5)

And I can run by press F5 directly after I have save it. And followed the output. Awesome.
The other simple program I’ve learned is to calculate the area of a circle below :

Phi=3.14
Prompt=”masukkan jejari=”
Jejari=input(prompt)
Print”Luas lingkaran adalah =”, (phi*jejari*jejari)
Print”Keliling lingkaran adalah =”, (2*phi*jejari)

Just need to be run and I get the output.
I hope I can study it more.

0 comments:

 
Free Host | lasik surgery new york