About 1,550,000 results
Open links in new tab
  1. How Big can a Python List Get? - Stack Overflow

    Feb 26, 2019 · Timing this way can be misleading -- most of the time is spent starting up the Python interpreter. A better way is: python -m timeit.py "l=range(12000); l=sorted(l, reverse=True)". On my machine this gives about 1/20th of the time for this example. –

  2. Handling very large numbers in Python - Stack Overflow

    Nov 13, 2017 · Python supports a "bignum" integer type which can work with arbitrarily large numbers. In Python 2.5+, this type is called long and is separate from the int type, but the interpreter will automatically use whichever is more appropriate. In Python 3.0+, long has been renamed int and the old int type has been dropped completely.

  3. How big can variable be, in python? - Stack Overflow

    Jul 11, 2010 · The largest positive integer supported by the platform’s Py_ssize_t type, and thus the maximum size lists, strings, dicts, and many other containers can have. On my MacBook Pro with a 64-bit build of CPython, it's quite sensibly 2 63 -1 bytes:

  4. python - Maximum value for long integer - Stack Overflow

    Mar 25, 2012 · The maximum value of an int can be found in Python 2.x with sys.maxint. It was removed in Python 3, but sys.maxsize can often be used instead. From the changelog: The sys.maxint constant was removed, since there is no longer a limit to the value of integers.

  5. Size of a Python list in memory - Stack Overflow

    You're looking at how lists are allocated (and I think maybe you just wanted to see how big things were - in that case, use sys.getsizeof()) When something is added to a list, one of two things can happen: The extra item fits in spare space. Extra space is needed, so a new list is made, and the contents copied across, and the extra thing added.

  6. What is the maximum float in Python? - Stack Overflow

    @Scott Griffiths: Not quite. sys.maxsize (introduced in Python 2.6) and sys.maxint are two different things. The first gives the maximum number of objects allowed in a collection (e.g., maximum size of a list, dict, etc.), and corresponds to a signed version of the C size_t type; the second is the point after which the int type switches to long, and is the max value of a C long.

  7. How to run a BigQuery query in Python - Stack Overflow

    Jul 10, 2017 · BigQuery DataFrames (bigframes)-- It can be used to to author queries with Python, instead of SQL. pandas-gbq-- Run a query and get the results as a pandas DataFrame. google-cloud-bigquery-- This is the client library for the BigQuery REST API. Use this to minimize dependencies and get results as Python objects. BigQuery DataFrames (bigframes):

  8. How can I use Python for large scale development?

    May 25, 2017 · And Python come with batteries included. I keep discovering them everyday. I had no idea of the number of modules I could use when I started and tried to rewrite existing stuff like everybody. It's OK, you can't get it all right from the beginning. You don't write Java, C++, Python, PHP, Erlang, whatever, the same way.

  9. Download large file in python with requests - Stack Overflow

    Requests is a really nice library. I'd like to use it for downloading big files (>1GB). The problem is it's not possible to keep whole file in memory; I need to read it in chunks. And this is a

  10. python - Handling big numbers in code - Stack Overflow

    Aug 11, 2012 · As you see, even in gmpy stringification of huge numbers can be hundreds of times slower than a simple addition (alas, it's an intrinsically complicated operation!); but in native Python code the ratio of times can go to stringification being tens of thousands times slower than a simple addition, so you really want to watch out for that ...