Sesiones de PyR
Input: arr[] = {1, 2, 3, 4, 5, 5, 5, 5, 5, 2, 2, 1, 1}
Output: 5
Explanation:
The subarray (5, 5, 5, 5, 5} has
maximum lengt { 1, 2, 3, 4 {1, 5, 6, 7}, 5, 6, 3, 4} mylist = [0, 1, 2, 3, 4, 5, 6, 7] for i in mylist: mylist.remove(i) print(myList)
output is
[1, 3, 5, 7]
Why not removing all first = {1, 2, 3, 4, 5, 6}
second = {4, 5, 6, 7, 8, 9}
third={2,4,6,8,0}
fourth=([4,6,8,5])
print(first | second | third )
prin why the code second-first print 8,9,7 and not 7,8,9?
first = {1, 2, 3, 4, 5, 6}
second = {4, 5, 6, 7, 8, 9}
print(second - first) a =[ 1, 1, 2, 3, 5, 8, 19, 21, 34, 55, 89
] Challenge sequence 3: 2, 3, 5, 11, 23, 29, 41, 53, 83, 89, 113, 131...... Code it...All languages welcome