python起步

<script>function StorePage(){d=document;t=d.selection?(d.selection.type!='None'?d.selection.createRange().text:''):(d.getSelection?d.getSelection():'');void(keyit=window.open('http://www.365key.com/storeit.aspx?t='+escape(d.title)+'&u='+escape(d.location.href)+'&c='+escape(t),'keyit','scrollbars=no,width=475,height=575,left=75,top=20,status=no,resizable=yes'));keyit.focus();}</script>

# Fig. D.1: test.py
# Simple program to demonstrate debugging.

# prompt user for input
integer = raw_input( "Enter an integer:\n" )
integer = int( integer )

if integer < 0:
print "%d is less than zero" % integer
else:
print "%d is not less than zero" % integer

python其实很好懂,不过要学到极致的话,就得下苦功夫。

raw_input函数是读取用户的输入的

int函数是将integer参数转换为整数

你可能感兴趣的:(C++,c,python,C#)