Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help!!
#2
You are using print twice. Once in the function and when calling the function.
Please use the bbtags when posting code. You should have a look at the help section on how to ask a question.

Quick example:
def afunc(arg):
    return arg

def afunc2(arg):
    print(arg)

print(afunc('I am using a return value and print'))

afunc2('Callinga function that has a print')

print(afunc2('Using both prints. This will return a None'))
Output:
I am using a return value and print Calling a function that has a print Using both prints. This will return a None None
I welcome all feedback.
The only dumb question, is one that doesn't get asked.
My Github
How to post code using bbtags
Download my project scripts


Reply


Messages In This Thread
Help!! - by prem_koresh_avraham - Feb-22-2024, 11:05 AM
RE: Help!! - by menator01 - Feb-22-2024, 11:51 AM
RE: Help!! - by paul18fr - Feb-22-2024, 01:43 PM

Forum Jump:

User Panel Messages

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