User Profile

Collapse

Profile Sidebar

Collapse
riverhorus
riverhorus
Last Activity: Jul 18 '08, 03:37 PM
Joined: Jul 8 '08
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • riverhorus
    replied to Python SyntaxError "Outside Function"
    Your suggestions corrected problem in previous block of script, but I'm getting the same error in the following block in line 4. Same error as before - "SyntaxErro r 'return' outside function." What does "outside function" mean or indicate? I've tried modifying the script modeled on the changes previously recommended, but nothing I do in terms of indentation helps. May I impose again to ask for help.

    I hope...
    See more | Go to post

    Leave a comment:


  • riverhorus
    replied to Python SyntaxError "Outside Function"
    My apologies. I didn't know about the code tags. I realized the indentations were important but didn't know how to display them properly. I'll try to do better next time.

    Anyway in the script the indentations are there but that hasn't affected the SyntaxError I keep getting saying the line "return None" is "outside function."

    Can you address that particular SyntaxError? I'll copy the suggested...
    See more | Go to post

    Leave a comment:


  • riverhorus
    started a topic Python SyntaxError "Outside Function"

    Python SyntaxError "Outside Function"

    I'm new to Python. I got this Python script from a friend. When I run it, I get an error message for line 7, "return None" saying "SyntaxErro r: 'return' outside function" Can someone explain what the SyntaxError is and how to fix it?

    Here's the block of script. The error occurs in line 7.

    def PC1(key, src, decryption=True ):
    sum1 = 0;
    sum2 = 0;
    keyXorVal = 0;
    if len(key)!=16:...
    See more | Go to post
No activity results to display
Show More
Working...