+ 4

what does res mean in python?

can someone please explain ive seen it in codes but i dont understand how or why it is used.

16th Jun 2018, 4:51 AM
Arketa
Arketa - avatar
7 Answers
+ 7
Yes, "res" is a common shortened version of "result". Sometimes folks will shorten a variable name too much so that it actually loses some readability.
16th Jun 2018, 5:25 AM
Shardis Wolfe
+ 5
The last line of the function is returnres , which exits the function and returns the value of the variable res . The return statement can appear in any place of a function. ... The built-in function max() in Python can accept various number of arguments and return the maximum of them
16th Jun 2018, 4:54 AM
Raj Chhatrala
Raj Chhatrala - avatar
+ 1
i have heard it can mean results... is that all or is there more?
16th Jun 2018, 4:52 AM
Arketa
Arketa - avatar
+ 1
ok thanks
16th Jun 2018, 4:55 AM
Arketa
Arketa - avatar
0
ok thanks alot :)
16th Jun 2018, 5:26 AM
Arketa
Arketa - avatar
0
i had that that problem too!
26th Mar 2020, 3:16 PM
Prince Jones