Skip to content

Magenaut

  • Home
  • Topics
    • Notes
    • Tutorial
    • Bug fixing
    • Extension
    • Server
  • Q&A
  • Privacy Policy
  • About

return

return two values from webservice

August 23, 2022 by Magenaut

Is is possible to return two values from a WebService to jQuery.

Categories ASP.NET, Q&A Tags asp.net, c#, return, web-services Leave a comment

Why does my recursive function return None?

August 22, 2022 by Magenaut

I have this function that calls itself:

Categories Python, Q&A Tags function, python, recursion, return Leave a comment

Why does “return list.sort()” return None, not the list?

August 22, 2022 by Magenaut

I’ve been able to verify that the findUniqueWords does result in a sorted list. However, it does not return the list. Why?

Categories Python, Q&A Tags list, python, return, sorting Leave a comment

How is returning the output of a function different from printing it?

August 22, 2022 by Magenaut

In my previous question, Andrew Jaffe writes:

Categories Python, Q&A Tags python, return Leave a comment

return, return None, and no return at all?

August 21, 2022 by Magenaut

Consider three functions:

Categories Python, Q&A Tags null, python, return Leave a comment

How can I return two values from a function in Python?

August 21, 2022 by Magenaut

I would like to return two values from a function in two separate variables.
For example:

Categories Python, Q&A Tags function, list, python, return, return-value Leave a comment

Recursive code returns None

August 20, 2022 by Magenaut

I really do not understand, why the code def isIn(char, aStr): ms = len(aStr)/2 if aStr[ms] == char: print 'i am here now' return True elif char>aStr[ms] and not ms == len(aStr)-1: aStr = aStr[ms+1:] elif char <aStr[ms] and not ms == 0: aStr = aStr[0:ms] else: return False isIn(char, aStr) print isIn('a', 'ab') does … Read more

Categories Python, Q&A Tags nonetype, python, recursion, return Leave a comment

How to use a return statement in a for loop?

August 19, 2022 by Magenaut

So I am working on a chat-bot for discord, and right now on a feature that would work as a todo-list. I have a command to add tasks to the list, where they are stored in a dict. However my problem is returning the list in a more readable format (see pictures).

Categories Python, Q&A Tags function, python, python-3.x, return Leave a comment

What’s the best way to return multiple values from a function?

August 19, 2022 by Magenaut

I have a function where I need to do something to a string. I need the function to return a boolean indicating whether or not the operation succeeded, and I also need to return the modified string. In C#, I would use an out parameter for the string, but there is no equivalent in Python. … Read more

Categories Python, Q&A Tags python, return, variables Leave a comment

return eats exception

August 12, 2022 by Magenaut

I found the following behavior at least weird:

Categories Python, Q&A Tags exception, finally, python, return Leave a comment
  1. michealSmith07 on Is there a way to dynamically refresh the less command?August 21, 2022

    That is a very nice post. I like this post.

  2. anonymous on Fix libwacom9 dependency issue when upgrade DebianJune 27, 2022

    saved my day!! Thanks for the help…

  3. sreedhar on Fix libwacom9 dependency issue when upgrade DebianMay 10, 2022

    Thanks its working

  4. saintnick on Fix libwacom9 dependency issue when upgrade DebianMay 10, 2022

    remove libwacom2 worked for me as well

  5. ranafoul on Fix libwacom9 dependency issue when upgrade DebianApril 22, 2022

    apt remove libwacom2 helped on kali 2022.01. gr8

.net ajax asp.net asp.net-core asp.net-mvc asp.net-mvc-3 asp.net-mvc-4 asp.net-web-api bash c# command-line css custom-post-types custom-taxonomy dataframe dictionary django entity-framework functions gridview html iis javascript jquery json linux list matplotlib numpy pandas php plugin-development plugins posts python python-2.7 python-3.x security shell shell-script sql string vb.net webforms wp-query

© 2026 Magenaut • Built with GeneratePress