We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Prepare
- Python
- Basic Data Types
- Tuples
- Discussions
Tuples
Tuples
Sort by
recency
|
1628 Discussions
|
Please Login in order to post a comment
This is a bad problem. hash() isn't guaranteed to give any particular value. If you run your code under PyPy3, it will say "Correct", but if you run it under Python 3, you get "Incorrect". The value produced by hash() shouldn't be relied upon.
n = raw_input() print hash(tuple([int(i) for i in raw_input().split()]))
Python is a versatile programming language known for its simplicity and readability. It's widely used in web development, data analysis, artificial intelligence, and more. Python's extensive libraries and frameworks, such as NumPy and Django, make it powerful for various applications. Its clean syntax emphasizes readability and reduces the cost of program maintenance. Python's community-driven development and strong support for integration with other languages make it a favorite among developers worldwide. https://verna-haywood.com/transformational-coaching/
n = int(input()) t = tuple(map(int, input().split()))
print(hash(t))