Skip to content
Snippets Groups Projects
Select Git revision
  • 6178332b685ccba55842944d86e830c352a6070c
  • master default
2 results

lecture note4-operation.py

Blame
  • lecture note4-operation.py 986 B
    Python 3.7.1 (v3.7.1:260ec2c36a, Oct 20 2018, 03:13:28) 
    [Clang 6.0 (clang-600.0.57)] on darwin
    Type "help", "copyright", "credits" or "license()" for more information.
    >>> 
    ============= RESTART: /Users/kimminsub/Documents/HELLO_WORLD.py =============
    HELLO, WORLD.
    >>> #이것은 주석입니다.
    >>> a=2020
    >>> a
    2020
    >>> b= a+3030
    >>> b
    5050
    >>> a=3
    >>> b=123456789
    >>> c=123456789012345678901234567890
    >>> a
    3
    b
    >>> 
    >>> c
    123456789012345678901234567890
    d
    >>> a
    3
    >>> b
    123456789
    >>> c
    123456789012345678901234567890
    >>> d
    Traceback (most recent call last):
      File "<pyshell#14>", line 1, in <module>
        d
    NameError: name 'd' is not defined
    >>> d= -12345678901234567890123456789012345677890
    >>> d
    -12345678901234567890123456789012345677890
    >>> e=-123456789
    >>> e
    -123456789
    >>> f=-3
    >>> 
    >>> f
    -3
    >>> type(f)
    <class 'int'>
    >>> type(d)
    <class 'int'>
    >>> type(e)
    <class 'int'>
    >>> a= 3+4
    >>> a
    7
    >>> b=7-10
    >>> b
    -3
    >>> c=7*-3
    >>> c
    -21
    >>> d=30//7
    >>> d
    4
    >>> e= 30%7
    >>> e
    2
    >>>