GitHub
github.com › atchyutn › hackerrank-python-solutions › blob › master › tuples.py
hackerrank-python-solutions/tuples.py at master · atchyutn/hackerrank-python-solutions
My Hacker Rank python solutions. Contribute to atchyutn/hackerrank-python-solutions development by creating an account on GitHub.
Author atchyutn
GitHub
github.com › absognety › Python-Hackerrank-Solutions › blob › master › Tuples.py
Python-Hackerrank-Solutions/Tuples.py at master · absognety/Python-Hackerrank-Solutions
Hackerrank Solutions for Python - Total 115 Challenges - Python-Hackerrank-Solutions/Tuples.py at master · absognety/Python-Hackerrank-Solutions
Author absognety
Optimization tricks in Python: lists and tuples
But you can change immutable object: Appending to a list contained in a tuple does not change the tuple. The immutable object does not change here · Well, you can get this to work with a copy-on-write implementation. I don't know enough about the Python runtime to decide whether that's feasible ... More on news.ycombinator.com
Hacker Rank Tuple Problem
Hi Everyone, I need your Help. I am new to Python and come across this Hacker Rank Tuple Problem and want to write this as simplest as possible. Q. Given an integer, n, and n space-separated integers as input, create a tuple, t, of those n integers. Then compute and print the result of hash(t). ... More on forum.freecodecamp.org
Faking a tuple class in python - Stack Overflow
I need to have a new type, say MyTuple, so that I can create objects like this: obj = MyTuple((1,2,3)), such as: obj behaves exactly as a native tuple (also in performance) isinstance(obj, tuple) More on stackoverflow.com
Do people actually use tuples?
In Python they are immutable which makes them suitable as keys for a dict which you can’t do with a list. More on reddit.com
Videos
GitHub
github.com › Evalle › HackerRank › blob › master › tuples.py
HackerRank/tuples.py at master · Evalle/HackerRank
You are given an integer, NN, on a single line. The next line contains NN space-separated integers. Create a tuple, TT, of those NN integers, then compute and print the result of hash(TT).
Author Evalle
GitHub
github.com › topics › python-tuple
python-tuple · GitHub Topics · GitHub
python-functions python-dictionary python-module python-list python-lists python-tuple python-set python-collections
GitHub
github.com › geekcomputers › Python › blob › master › tuple.py
Python/tuple.py at master · geekcomputers/Python
print('Individual elements of Tuple are') for i in a: print(i,end=' ') print() print('Value at index number 3 is:',a[3]) print('Values from index no 2 are',a[2:]) print('Length of tuple is',len(a)) print('Maximum value from tuple is ',max(a)) ...
Author geekcomputers
GitHub
github.com › topics › python-tuple-methods
python-tuple-methods · GitHub Topics · GitHub
June 12, 2022 - python-tutorials list-comprehension python-dictionary python-string-maupulation python-lists python-sets python-tuples list-comprehensions python-strings python-tutorial-notebook python-datatypes python-string-methods python4everybody python-tutorial-github python4datascience python-list-methods python-tuple-methods python-dictionary-methods python-sets-methods tutor-milaan9
Hacker News
news.ycombinator.com › item
Optimization tricks in Python: lists and tuples | Hacker News
June 17, 2018 - But you can change immutable object: Appending to a list contained in a tuple does not change the tuple. The immutable object does not change here · Well, you can get this to work with a copy-on-write implementation. I don't know enough about the Python runtime to decide whether that's feasible ...
freeCodeCamp
forum.freecodecamp.org › python
Hacker Rank Tuple Problem - Python - The freeCodeCamp Forum
January 27, 2023 - Hi Everyone, I need your Help. I am new to Python and come across this Hacker Rank Tuple Problem and want to write this as simplest as possible. Q. Given an integer, n, and n space-separated integers as input, create a tuple, t, of those n integers. Then compute and print the result of hash(t). ...
GitHub
github.com › topics › python-hacking
python-hacking · GitHub Topics · GitHub
Python script to automatically steal all the files and information from a computer using an USB device. Created just for educational purposes. hack cybersecurity cracking hacking-tool ethical-hacking python-hacking
GitHub
gist.github.com › moulik-source › a55865cd6b296fb9b4ff173fd900fb7a
tuples in python · GitHub
tuples in python · This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters ·
Top answer 1 of 2
1
class MyTuple(object):
def __init__(self, iterable):
self.data = tuple(iterable)
def __getitem__(self, i):
return tuple.__getitem__(self.data, i)
t = MyTuple((1, 2, 3))
print(t[1])
print(isinstance(t, tuple))
Other methods analogously.
Still not a true tuple performancewise, but the closest I can think of... probably.
2 of 2
0
The main problem you'll hit with performance is that Python's underlying collateral is implemented in highly-optimized C (or other language -- there are a dozen or so good implementations, and more coming).
When you implement something in Python, remember that it's interpreted, or partially-compiled at best. You cannot get optimum performance when each line has to be reinterpreted at run time, even given good intermediate code.
HackMD
hackmd.io › @topics › B1uvJ6Nja
Tuples in Python | Python Tuples with Examples - Scaler Topics - HackMD
3. Optimal use of tuples depends on their intended application; misapplication can lead to inefficiencies, such as substituting for lists, sets, or dictionaries. 4. Choosing the appropriate data structure requires careful consideration of use cases to ensure efficient data handling and manipulation. ::: ... Sign in via Google Sign in via Facebook Sign in via X(Twitter) Sign in via GitHub Sign in via Dropbox Sign in with Wallet ·
GitHub
github.com › Gaurav715 › Python › blob › master › Tuples - Solution_Py3.ipynb
Python/Tuples - Solution_Py3.ipynb at master · Gaurav715/Python
"## Tuples" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "*Suggested Answers follow (usually there are multiple ways to solve a problem in Python).*" ] }, { "cell_type": "markdown", "metadata": { "collapsed": true ·
Author Gaurav715
Retool
retool.com › blog › 12-days-of-retool-two-tuple-hacks
Retool Blog | 12 Days of Retool: Two Tuple Hacks
July 9, 2025 - If JavaScript doesn't have tuples, when is it beneficial to pretend as if they do exist? This technique is handy in two situations: When you'd like to pass around data that is naturally related using a single object reference · When position has actual meaning for the data being handled · In the Python example above, we created a tuple representing an X/Y coordinate pair.
Medium
medium.com › swlh › hacking-python-applications-5d4cd541b3f1
Hacking Python Applications. And how attackers exploit common… | by Vickie Li | The Startup | Medium
November 15, 2019 - Remember, a pickle can represent any arbitrary Python object. When an application unpickles a pickle, it is instantiating a new object of that class. The pickle class allows objects to declare how they should be pickled via the __reduce__ method. This method takes no argument and returns either a string or a tuple.