+1 vote
in Class 11 by kratos

Write the output of the given Python code :

!/user/bin/python

list1, list2 = [123, ‘xyz’], [456, ‘abc’]

print cmpt(list1, list2);

print cmp(list2, list1);

list3 = list2 + [786];

print cmp(list2, list3)

1 Answer

+3 votes
by kratos
 
Best answer

This will produce the following result:

-1

1

-1

...