Posts by Gabriel Borges • 41 points
2 posts
-
2
votes2
answers426
viewsQ: union of lists
I am doing this algorithm where I have to do the union of two lists and the repeated numbers can only appear once. But it’s gone wrong, someone to save me? def uniao(l1,l2,r=[]): if len(l1) == 0:…
pythonasked Gabriel Borges 41 -
0
votes2
answers350
viewsQ: Recursive algorithm for calculating arithmetic mean
I am making an algorithm that has to calculate the average values of a list, but with what I did does not present the correct result. The sum works, but when it comes to dividing, no. def…