Skip to content

Conversation

@galenseilis
Copy link
Contributor

@galenseilis galenseilis commented Apr 9, 2025

  • After tinkering with timeit I noticed that usually it is faster to multiply a singleton list by a desired constant than it is to construct and use the range iterator.
  • In one case I noticed a 3X improvement.
  • This is suitable for constructing a new list containing the same constant value.
@geraintpalmer geraintpalmer changed the base branch from master to updates-by-pr June 4, 2025 13:39
This allows for unique objects rather than pointers to the same object.
@geraintpalmer geraintpalmer merged commit 35c99c9 into CiwPython:updates-by-pr Jun 4, 2025
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants