一、Argument And Parameter
- the user who use the function say "give you a argument".
- the function say "Thank you for you parameter".
def printMyAddress(someName,houseNum):
print somename
print houseNum,
print "Main Street"
print "Ottawa,Ontario,Canada"
print "K2M 2E9"
print
printMyAddress("Carter Sande", "45")
printMyAddress("Jack Black", "64")
printMyAddress("Tom Green", "22")
printMyAddress("Todd White", "36")
def printMyAddress(myName):
print myName
print "123 Main Street"
print "Ottawa,Ontario",Canada
print "K2M 2E9"
print
printMyAddress("Carter Sande")
The function return the greatest common divisor
# Filename : test.py
# author by : www.runoob.com
# define a function
def hcf(x, y):
"""The function return the greatest common divisor"""
# get the minimum value
if x > y:
smaller = y
else:
smaller = x
for i in range(1, smaller + 1):
if ((x % i == 0) and (y % i == 0)):
hcf = i
return hcf
# user enter two numbers
num1 = int(input("enter the First number: "))
num2 = int(input("enter the Second number: "))
print(num1, "and", num2, "have the greatest common divisor that is", hcf(num1, num2))
reformat selected imports |
重新格式化选定的导入 |
optimize |
使最优化[o:ptimaiz] |
infer |
推断,猜想,推理 |
refactor this |
重构这个 |
module |
组件,模 |
video captioning |
视频字幕 |
keystroke |
按键 |
keymap |
键盘布局 |
specify the scheme you want to change |
指定要改的方案 |
quick switch scheme |
快速切换方案 |
interpreter |
翻译器[in‘te:rprite(r)] |
prefix key pressed |
前缀键按下 |
refactor |
重构 |
studio |
画室,工作室 |
clipboard |
剪贴板[‘klipbo:rd] |
on the main menu |
在主菜单中 |
inspection |
[in‘spektion]检验,检查 |
specify the desired scope |
指定期望范围 |
arrow key |
箭头键 |
arrow keys to locate the necessary files or folders |
查找必要文件或文件夹的箭头键 |
navigation bar |
导航栏 |
scratch file |
临时文件 |
the shorcuts of PyCharm
Alt+Shift+C |
quickly review your recent changes to the project |
Ctrl+ space bar |
use basic completion |
Ctrl+‘ |
switch 1.Color Scheme 2.Code Style Scheme 3.Keymap 4.View Mode 5.Look and Feel |
Ctrl+Alt+Shift+I |
to quickly find and run an inspection,start typing the name of the inspection or its group.Choose the desired inspection from the suggestion list and then specify the desired scope. |
Ctrl+ |
comments or uncomments the current line or several selected lines with single line comments. |
Alt+Home |
show the Navigation bar,and arrow keys to locate the necessary files or folders. |
shortcuts
原文:https://www.cnblogs.com/hugeng007/p/9348439.html