- 博客(99)
- 资源 (3)
- 收藏
- 关注

原创 PyQt 5 教程
前言笔记中有什么前言接触Python有一阵子了,由于我的工作内容是人力资源,所以不能像专业队员一样在实际切入相关项目。但对Python的热衷程度仍然不减,尤其是对GUI开发的喜爱。在众多GUI开发包中,毫无疑问的选择了Qt1,关于Qt是什么可以自行百度,或通过脚注进行了解(我也是粘贴的…)。那么针对Python语言,Phil Thompson进行了整合,进而形成了PyQt2。目前学习进度比较缓慢,
2016-03-01 12:41:03
2209

原创 Python 内建函数(Built-in Functions)
关于内置函数关于列表说明内置函数列表关于内置函数Python 3.4和2.7两个版本比对会有部分内置函数差异,2.7版本中包含80种内置函数,3.4版本中缩减为68种,关于缩减和修改会在详情中给出说明,并在列表中以’*’号标注。同时,新增内容以’!’号标注。关于列表说明以下列表内罗列的内置函数主体以3.4发布的手册为准,表格中的内置函数依照字母排序,并插入链接,点击进入查看详细使用说明,只要你
2015-04-09 08:22:51
799

原创 Python Note
关于Python不得不说的事儿絮叨这是什么鬼为什么是优快云关于版本和运行平台我想写什么Python安装和使用Python语言参考The Python Language ReferencePython标准库The Python Standard LibraryPython编程实例Note关于Python不得不说的事儿絮叨学习Python有些日子,因为学习养成了记笔记的习惯,费了不
2015-04-08 23:46:29
340
原创 Python 内建常量(Built-in Constants)
基本常量FalseTrueNoneNotImplementedEllipsis__debug__site模块增加的常量quitcodeNoneexitcodeNonecopyrightlicensecredits基本常量内建域名中只有很少一部分常量,它们是:False[布尔类型][1]的否定值,分配给False关键字是非法的,并且会引发SyntaxError。True¶布尔类
2017-03-28 11:09:39
1963
原创 Python 内建函数 - __import__(name, globals=None, locals=None, fromlist=(), level=0)
函数说明参数解释版本变更函数说明 注意:这是一个高级函数,不像[importlib.import_][1]模块,不需要在每天的Python编程中使用。该函数被[import][2]语句调用,为了改变import语句的语义,它可以被替换(通过导入内建模块并指派为builtins.__import__)。但强烈不建议这么做,因为使用import可以更容易达成目的,并且不会引起代码问题。同样不建
2017-03-27 17:31:43
2827
原创 Python 内建函数 - zip(*iterables)
用法拓展阅读用法创建一个迭代器,它可以聚集来自每个iterables的元素。返回的是元组的迭代器,其第i项元组包含了i个来自每个参数序列或迭代的元素,当用尽输入最短的迭代时迭代器停止。单参数下,它返回一个1次元组迭代器;无参数时,它返回一个空迭代,等于:def zip(*iterables): # zip('ABCD', 'xy') --> Ax By sentinel = ob
2017-03-27 01:09:51
873
原创 Python 内建函数 - vars([object])
Manual直译实例拓展阅读ManualReturn the __dict__ attribute for a module, class, instance, or any other object with a __dict__ attribute.Objects such as modules and instances have an updateable __dict__ attri
2017-03-27 00:35:47
653
原创 Python 内建函数 - type(object)
参数形式Manual直译实例拓展阅读参数形式type(object)type(name, bases, dict)ManualWith one argument, return the type of an object. The return value is a type object and generally the same object as returned by obj
2017-03-27 00:13:52
551
原创 Python 内建函数 - tuple([iterable])
Manual直译实例拓展阅读ManualRather than being a function, tuple is actually an immutable sequence type, as documented in Tuples and Sequence Types — list, tuple, range.直译与其说是函数,tuple实际上是一个不可变序列类型,详情参考元组和序列类
2017-03-26 23:59:36
607
原创 Python 内建函数 - super([type[, object-or-type]])
函数参考函数参考返回一个代理对象,其可以用委派的方法调用类型的父系或兄弟类,这对于访问继承的方法(已经被重写的方法)很有用,检索顺序与使用[getattr()][1]相同。类型的[__mro__][2]属性列出了getattr()和super()所用的方法解析检索顺序,该属性是动态的,并且无论何时更新继承层次都可以进行改变。如果第二个参数缺省,super对象的返回是未被绑定的;如果第二个参数是一个对
2017-03-24 15:15:48
1022
原创 Python 内建函数 - sum(iterable[, start])
Manual直译实例拓展阅读ManualSums start and the items of an iterable from left to right and returns the total. start defaults to 0. The iterable‘s items are normally numbers, and the start value is not allow
2017-03-23 17:37:42
1820
原创 Python 内建函数 - str(object='')
参数形式Manual直译实例拓展阅读参数形式str(object=”)str(object=b”, encoding=’utf-8’, errors=’strict’)ManualReturn a str version of object. See str() for details.str is the built-in string class. For general info
2017-03-23 16:59:57
629
原创 Python 内建函数 - staticmethod(function)
Manual直译拓展阅读ManualReturn a static method for function.A static method does not receive an implicit first argument. To declare a static method, use this idiom:class C: @staticmethod def f(arg1
2017-03-23 16:47:17
401
原创 Python 内建函数 - sorted(iterable[, key][, reverse])
Manual直译实例基本排序key函数operator模块函数升序和降序排序稳定性和复杂排序其他拓展阅读ManualReturn a new sorted list from the items in iterable.Has two optional arguments which must be specified as keyword arguments.key speci
2017-03-23 09:43:38
890
原创 Python 内建函数 - slice(stop)
参数形式Manual直译实例Note拓展阅读参数形式slice(stop)slice(start, stop[, step])ManualReturn a slice object representing the set of indices specified by range(start, stop, step). The start and step arguments de
2017-03-22 18:47:55
490
原创 Python 内建函数 - setattr(object, name, value)
Manual直译实例拓展阅读ManualThis is the counterpart of getattr(). The arguments are an object, a string and an arbitrary value. The string may name an existing attribute or a new attribute. The function ass
2017-03-22 18:24:50
542
原创 Python 内建函数 - set([iterable])
Manual直译实例拓展阅读ManualReturn a new set object, optionally with elements taken from iterable. set is a built-in class. See set and Set Types — set, frozenset for documentation about this class.For oth
2017-03-22 17:21:44
329
原创 Python 内建函数 - round(number[, ndigits])
Manual直译实例NoteManualReturn the floating point value number rounded to ndigits digits after the decimal point. If ndigits is omitted or is None, it returns the nearest integer to its input. Delegates
2017-03-22 17:12:00
1584
原创 Python 内建函数 - reversed(seq)
Manual直译实例Note拓展阅读ManualReturn a reverse iterator. seq must be an object which has a __reversed__() method or supports the sequence protocol (the __len__() method and the __getitem__() method with
2017-03-22 16:29:33
504
原创 Python 内建函数 - repr(object)
Manual直译实例拓展阅读ManualReturn a string containing a printable representation of an object. For many types, this function makes an attempt to return a string that would yield an object with the same val
2017-03-22 16:20:28
308
原创 Python 内建函数 - range(stop)
参数形式Manual直译参数说明实例拓展阅读参数形式range(stop)range(start, stop[, step])ManualRather than being a function, range is actually an immutable sequence type, as documented in Ranges and Sequence Types — lis
2017-03-22 16:07:07
564
原创 Python 内建函数 - property(fget=None, fset=None, fdel=None, doc=None)
函数功能参数说明用法版本变更函数功能返回一个property属性参数说明fget是一个用来获取属性值的函数;fset是一个用来设置属性值的函数;fdel是一个用来删除某个属性值的函数doc为属性创建一个文档字符串用法典型用法是定义一个属性x的管理:class C: def __init__(self): self._x = None def getx(s
2017-03-22 11:58:04
2373
原创 Python 内建函数 - print(*objects, sep=' ', end='\n', file=sys.stdout, flush=False)
Manual直译实例拓展阅读ManualPrint objects to the text stream file, separated by sep and followed by end. sep, end and file, if present, must be given as keyword arguments.All non-keyword arguments are conve
2017-03-21 17:40:31
2051
1
原创 Python 内建函数 - pow(x, y[, z])
Manual直译实例ManualReturn x to the power y; if z is present, return x to the power y, modulo z (computed more efficiently than pow(x, y) % z). The two-argument form pow(x, y) is equivalent to using the
2017-03-21 17:15:14
3262
原创 Python 内建函数 - ord(c)
Manual直译实例拓展阅读ManualGiven a string representing one Unicode character, return an integer representing the Unicode code point of that character. For example, ord(‘a’) returns the integer 97 and ord(‘
2017-03-21 16:49:59
871
原创 Python 内建函数 - open(file, mode='r', buffering=-1, encoding=None, errors=None, newline=None...)
手册直译因为该函数的官方参考手册引文篇幅过大,不再本文中体现,如有需要查询原引文内容的,详见官方手册。手册直译打开发文件并返回相应的文件对象,如果文件不能打开,则引发OSError异常。 file可以是字符串或字节对象,用于给出要打开文件路径名(绝对或相对当前工作目录)或要打包文件的整数文件描述符。如果给定某个文件描述符,当返回的I/O对象关闭时那么它会被关闭,除非closefd设为False。
2017-03-21 14:45:15
4005
3
原创 Python 内建函数 - oct(x)
Manual直译实例拓展阅读ManualConvert an integer number to an octal string. The result is a valid Python expression. If x is not a Python int object, it has to define an __index__() method that returns an int
2017-03-20 11:50:00
445
原创 Python 内建函数 - object
Manual直译实例Note拓展阅读ManualReturn a new featureless object. object is a base for all classes. It has the methods that are common to all instances of Python classes. This function does not accept any
2017-03-20 11:45:10
779
原创 Python 内建函数 - next(iterable[, default])
Manual直译实例拓展阅读ManualRetrieve the next item from the iterator by calling its __next__() method. If default is given, it is returned if the iterator is exhausted, otherwise StopIteration is raised.直译通
2017-03-20 11:15:20
317
原创 Python 内建函数 - min(iterable, *[, key, default])
参数形式Manual直译实例拓展阅读参数形式min(iterable, *[, key, default])min(arg1, arg2, *args[, key])ManualReturn the smallest item in an iterable or the smallest of two or more arguments.If one positional argume
2017-03-20 11:07:39
743
1
原创 Python 内建函数 - memoryview(obj)
Manual直译实例Note拓展阅读ManualReturn a “memory view” object created from the given argument. See Memory Views for more information.直译根据给定参数,创建并返回一个“内存视图”对象,详情见内存视图实例>>> v = memoryview(b'abcefg')>>> v[1
2017-03-20 10:27:52
917
原创 Python 内建函数 - max(iterable, *[key, default])
参数形式Manual直译实例拓展阅读参数形式max(iterable, *[key, default])max(arg1, arg2, *args[, key])ManualReturn the largest item in an iterable or the largest of two or more arguments.If one positional argument i
2017-03-20 10:19:10
877
原创 Python 内建函数 - map(function, iterable, ...)
Manual直译实例拓展阅读ManualReturn an iterator that applies function to every item of iterable, yielding the results. If additional iterable arguments are passed, function must take that many arguments and
2017-03-20 09:47:11
481
原创 Python 内建函数 - locals()
Manual直译实例拓展阅读ManualUpdate and return a dictionary representing the current local symbol table. Free variables are returned by locals() when it is called in function blocks, but not in class blocks
2017-03-17 17:50:16
351
原创 Python 内建函数 - list([iterable])
Manual直译实例ManualRather than being a function, list is actually a mutable sequence type, as documented in Lists and Sequence Types — list, tuple, range.直译与其作为函数,列表实际上是可变序列类型,详情见[列表和序列类型 — 列表、元组、区间][1]
2017-03-17 17:26:10
1090
原创 Python 内建函数 - len(s)
Manual直译实例ManualReturn the length (the number of items) of an object. The argument may be a sequence (such as a string, bytes, tuple, list, or range) or a collection (such as a dictionary, set, or fr
2017-03-17 17:19:01
3367
原创 Python 内建函数 - iter(object[, sentinel])
Manual直译实例拓展阅读ManualReturn an iterator object. The first argument is interpreted very differently depending on the presence of the second argument. Without a second argument, object must be a collec
2017-03-17 14:55:59
978
原创 Python 内建函数 - issubclass(class, classinfo)
Manual直译实例拓展阅读ManualReturn true if class is a subclass (direct, indirect or virtual) of classinfo. A class is considered a subclass of itself. classinfo may be a tuple of class objects, in which ca
2017-03-16 16:51:59
827
原创 Python 内建函数 - isinstance(object, classinfo)
Manual直译实例ManualReturn true if the object argument is an instance of the classinfo argument, or of a (direct, indirect or virtual) subclass thereof. If object is not an object of the given type, the
2017-03-16 16:43:11
766
原创 Python 内建函数 - int(x=0)
参数形式Manual直译实例拓展阅读参数形式int(x=0)int(x, base=10)ManualReturn an integer object constructed from a number or string x, or return 0 if no arguments are given. If x is a number, return x.__int__(). Fo
2017-03-16 16:24:23
1533
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人