편집 기록

편집 기록
  • 프로필 nowp님의 편집
    날짜2020.04.28

    Python 질문 while not str


    name = ''
    
    while not name:                                                #### ➊
        print('Enter your name:')    
        name = input()
    
    print('How many guests will you have?')
    numOfGuests = int(input())
    
    if numOfGuests:                                                #### ➋
        print('Be sure to have enough room for all your guests.')  #### ➌     
    
    print('Done')
    

    이 코드에서 while not namewhile not name != "이라 들었는데 while not name != " 이게 name이 거짓이 아닌게 아닐때 까지 라는 뜻 인가요? 너무 헷갈리는데 무슨 뜻인지 설명좀 해주시면 감사하겠습니다

  • 프로필 편집요청빌런님의 편집
    날짜2020.04.28

    Python 질문


    name = ''
    
    ➊ while not name:
    
        print('Enter your name:')
    
        name = input()
    print('How many guests will you have?')
    
    numOfGuests = int(input())
    
    ➋ if numOfGuests:
    
        ➌ print('Be sure to have enough room for all your guests.')
    
    
    print('Done')
    

    이 코드에서 while not namewhile not name != "이라 들었는데 while not name != " 이게 name이 거짓이 아닌게 아닐때 까지 라는 뜻 인가요? 너무 헷갈리는데 무슨 뜻인지 설명좀 해주시면 감사하겠습니다

  • 프로필 nowp님의 편집
    날짜2020.04.28

    Python 질문 while not str


    name = ''
    
    while not name:                                               ####  ➊ 
        print('Enter your name:')    
        name = input()
    
    
    print('How many guests will you have?')
    numOfGuests = int(input())
    if numOfGuests:                                               #### ➋
        print('Be sure to have enough room for all your guests.') #### ➌     
    
    print('Done')
    

    이 코드에서 while not namewhile not name != "이라 들었는데 while not name != " 이게 name이 거짓이 아닌게 아닐때 까지 라는 뜻 인가요? 너무 헷갈리는데 무슨 뜻인지 설명좀 해주시면 감사하겠습니다

  • 프로필 알 수 없는 사용자님의 편집
    날짜2020.04.28

    Python 질문


    name = ''

    ➊ while not name:

    print('Enter your name:')
    
    name = input()
    

    print('How many guests will you have?')

    numOfGuests = int(input())

    ➋ if numOfGuests:

    ➌ print('Be sure to have enough room for all your guests.')
    

    print('Done')

    이 코드에서 while not name 이 while not name != "이라 들었는데 while not name != " 이게 name이 거짓이 아닌게 아닐때 까지 라는 뜻 인가요? 너무 헷갈리는데 무슨 뜻인지 설명좀 해주시면 감사하겠습니다