Python Forum
A simple "If...Else" question from a beginner
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
A simple "If...Else" question from a beginner
#3
(Jul-11-2022, 02:07 AM)menator01 Wrote: if you do not want the else to execute change all other if's except first to elif. the else only works with last if.

Hi mentor!

Thank you so much for your help! I changed the If into elif except the first one and it worked!
Sorry I'm embarrassed to ask what do you mean by "the else only works with last if"? And why the previous coding didn't work as desired? Thank you again! It helped me enormously!
Reply


Messages In This Thread
RE: A simple "If...Else" question from a beginner - by Serena2022 - Jul-11-2022, 02:22 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Very Beginner question on simple variables Harvy 1 392 Apr-12-2024, 12:03 AM
Last Post: deanhystad
  Simple Question - ' defined as "a". ?' Ryan012 10 1,928 May-27-2023, 06:03 PM
Last Post: Ryan012
  Very simple question about filenames and backslashes! garynewport 4 2,180 Jan-17-2023, 05:02 AM
Last Post: deanhystad
  Python Tkinter Simple Multithreading Question AaronCatolico1 5 1,801 Dec-14-2022, 11:35 PM
Last Post: deanhystad
Question Beginner Boolean question [Guessing game] TKB 4 2,510 Mar-22-2022, 05:34 PM
Last Post: deanhystad
  Simple arithmetic question ebolisa 5 2,199 Dec-15-2021, 04:56 PM
Last Post: deanhystad
  Simple code question about lambda and tuples JasPyt 7 3,604 Oct-04-2021, 05:18 PM
Last Post: snippsat
Big Grin question about simple algorithm to my problem jamie_01 1 1,768 Oct-04-2021, 11:55 AM
Last Post: deanhystad
  Beginner question NameError amazing_python 6 2,671 Aug-13-2021, 07:28 AM
Last Post: amazing_python
  Beginner question - storing values cybertron2 4 3,381 Mar-09-2021, 04:21 AM
Last Post: deanhystad

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020