a page a day 3

last time we talk about the constant that holds something and cannot changed in the runtime process of one programm and the string ,which is said to be the most uesd constant later on . as the c/c++,we also have identifiers (in all programming languages). the rule of naming them will not appear here,for it did in c/c++.it will be boring for me to tell it .so just leave it out.

as a matter of facts ,anything python refers to is called an object.below are something ways you can do to write a programm,which is pretty COOL i think and fesible .
1. open your favorite editor ,such as vim ,gvim,emacs,notepad.
2.enter the programm you have thought over and want   to commit into paper.
3.save it as a file with the filename in the comments at the begining of your programm  . i follow the convention of .py.
4.run the programm with the command line python filename.py or use the commands  like this : chmod a+x filename.py  
        ./filename.py

so charimg!  what i will stress  here is that unlike the c/c++ ,we  need not to
declare a variable and date type . keep it in mind.
i will cp a instance(in my favorite vim):
# Filename : var.py
i=9
print i
i=i+1
print i

s='''this is wolf london
this is chrysanthemumwolf'''
print s

and i save it as var.py  and run it . it shows that:
9
10
this is wolf london
this is chrysanthemumwolf
 we have make it .
and boost a little day by day .

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值