Python Forum
Simple problem with functions and returns
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Simple problem with functions and returns
#8
(Mar-17-2021, 12:10 PM)danlopek14q Wrote: Does that mean it has to change from integer to a string? I have no clue that's my main problem
Your menu() function should return int. Based on value returned from menu() you need to decide what operation (str) to pass as argument to your function started(). Have you learned about dict or other data structures?
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs

Reply


Messages In This Thread
RE: Simple problem with functions and returns - by buran - Mar-17-2021, 02:04 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
Question Functions and if elif problem Bruizeh 2 3,824 Aug-27-2021, 03:37 AM
Last Post: naughtyCat
  simple function problem stereokim123 5 3,389 Aug-26-2021, 04:44 PM
Last Post: naughtyCat
  I have a simple problem ahmed 5 2,593 Jul-17-2021, 02:50 PM
Last Post: ahmed
  Functions returns content of dictionary as sorted list kyletremblay15 1 2,086 Nov-21-2019, 10:06 PM
Last Post: ichabod801
  Problem with a simple script Niko047 2 3,374 Jul-21-2017, 09:02 PM
Last Post: Niko047

Forum Jump:

User Panel Messages

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