Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

not able to execute print command on page 16 of documentation #74938

Closed
VishalDevgn mannequin opened this issue Jun 25, 2017 · 2 comments
Closed

not able to execute print command on page 16 of documentation #74938

VishalDevgn mannequin opened this issue Jun 25, 2017 · 2 comments
Labels
build The build process and cross-build

Comments

@VishalDevgn
Copy link
Mannequin

VishalDevgn mannequin commented Jun 25, 2017

BPO 30753
Nosy @stevendaprano
Files
  • 1.png: png image from python 3.6
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = <Date 2017-06-25.11:26:20.624>
    created_at = <Date 2017-06-25.11:11:27.078>
    labels = ['build', 'invalid']
    title = 'not able to execute print command on page 16 of documentation'
    updated_at = <Date 2017-06-25.11:26:20.614>
    user = 'https://bugs.python.org/VishalDevgn'

    bugs.python.org fields:

    activity = <Date 2017-06-25.11:26:20.614>
    actor = 'steven.daprano'
    assignee = 'none'
    closed = True
    closed_date = <Date 2017-06-25.11:26:20.624>
    closer = 'steven.daprano'
    components = []
    creation = <Date 2017-06-25.11:11:27.078>
    creator = 'Vishal Devgn'
    dependencies = []
    files = ['46974']
    hgrepos = []
    issue_num = 30753
    keywords = []
    message_count = 2.0
    messages = ['296821', '296822']
    nosy_count = 2.0
    nosy_names = ['steven.daprano', 'Vishal Devgn']
    pr_nums = []
    priority = 'normal'
    resolution = 'not a bug'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'compile error'
    url = 'https://bugs.python.org/issue30753'
    versions = ['Python 3.6']

    @VishalDevgn
    Copy link
    Mannequin Author

    VishalDevgn mannequin commented Jun 25, 2017

    >>> a, b = 0, 1
    >>> while b < 1000:
    ... print(b, end=',')
    ... a, b = b, a+b

    in 3.6 as soon as i write print command, it displays an indentation error.

    @VishalDevgn VishalDevgn mannequin added the build The build process and cross-build label Jun 25, 2017
    @stevendaprano
    Copy link
    Member

    This is a bug in your code, not Python, and the error tells you how to fix it. You have to indent the block.

    >>> while b < 1000:
    ...     print(b, end=',')
    ...     a, b = b, a+b

    Remember to press TAB or spacebar inside indented blocks.

    You should work through the tutorial.

    https://docs.python.org/3/tutorial/index.html

    By the way, you say page 16 of which documentation? Are you reading from a book? Which book?

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    build The build process and cross-build
    Projects
    None yet
    Development

    No branches or pull requests

    1 participant