Type Erorr nr2

Hi
I have got the TypeError. I use lists at the same way in my other programs it works excellent, but just in this program I have got problem don’t know how to solve it?
Traceback (most recent call last):
File "E:\extra_b.py", line 42, in <module>
ordna(pile)
File "E:\extra_b.py", line 22, in ordna
new_num = num-1
TypeError: unsupported operand type(s) for -: 'list' and 'int'

I see I want to work with a list of number and my first function return a list of number. I don’t want to mix a deferent type int and list.
But when I did as you said, I got a deferent list which looks like that:
First print --> [2, 5, 7, 7] 4
Second print --> (4, [2, 5, 7, 7])
I don’t know why they are deferent?
May be same where my program has mixed a deferent kind of type?? I don’t see it !

Obviously this is not a list of numbers, so you want to take a look at the function that returns this. Add print statements to see what is going on throughout the program until you understand what is happening

Hi
Thanks guys I find the reason of error but I still don’t understand fallowing.
My first function dela ( ) return pile and sum, pile is a list of numbers and sum is a digit but I used only pile which is a list and sent it to my other function. Sum which is a digit and returns by function but didn´t used.
If a function return a, b can I use only a?? And how b can influence result of a??

To work the way you want, your original code would have been
c=lasin ()
sum, pile=dela(c)
ordna(pile)
If the function returns two variables, but the calling line only receives one variable, then python returns one tuple, because you only have one block of memory allocated for the return.

Hi. so this is actually a continuation from another question of mine[Here](https://www.daniweb.com/programming/software-development/threads/506795/dynamically-add-values-into-datagridview-cell-from-listbox-vb2010) but i was advised to start a new thread as the original question …

I have a 2d matrix with dimension (3, n) called A, I want to calculate the normalization and cross product of two arrays (b,z) (see the code please) for each column (for the first column, then the second one and so on).
the function that I created to find the ...

Write a C program that should create a 10 element array of random integers (0 to 9). The program should total all of the numbers in the odd positions of the array and compare them with the total of the numbers in the even positions of the array and indicate ...