Python Forum
defining a function to see if a list is sorted
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
defining a function to see if a list is sorted
#10
If I back up my return True statement to fall in the same column as my for loop it still returns True. Shouldn't the if loop run for each value in the list per the for loop?

I figured it out. Thank you for helping me @Gribouillis!! Thank you for not just giving me the answer. I want to work my way through it so I understand it. Sometimes I just need a kick in the pants to change the way I'm looking at it.
Reply


Messages In This Thread
RE: defining a function to see if a list is sorted - by Siylo - Nov-29-2018, 12:34 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  A function that checks if the list is sorted pooyan89 16 18,033 Apr-22-2024, 09:14 AM
Last Post: DeaD_EyE
  How to Sorted and display the Subclasses of BaseException Fernando_7obink 9 4,048 Feb-10-2021, 12:04 PM
Last Post: buran
  Defining x and y axes in Spectrogram Function amy5678 3 2,442 Nov-29-2020, 01:42 PM
Last Post: jefsummers
  Functions returns content of dictionary as sorted list kyletremblay15 1 2,177 Nov-21-2019, 10:06 PM
Last Post: ichabod801
  python 3.4.3 Question a defining function student8 1 4,439 Oct-02-2017, 07:59 PM
Last Post: nilamo
  sorted list not displaying Crackity 6 5,342 Jul-18-2017, 12:50 PM
Last Post: sparkz_alot

Forum Jump:

User Panel Messages

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