Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options not deleted user 132397

Python is a dynamically typed, high-level interpreted programming language. Its design focuses on clear syntax, an intuitive approach to object-oriented programming, and making the right way to do things obvious. Python supports modules and exceptions, and has an extensive standard module library. Python is general-purpose and thus used widely, from the web to embedded systems.

1 vote

What is the preferred object to store this type of data structure

There are a few different ways to access the data and your needs to access it should dictate which format you use. Right now, with a dictionary of dictionaries, if you want to find the nth document, y …
user1118321's user avatar
  • 4,981
5 votes
Accepted

I order my Python imports by name length. Does this make any sense?

Also, I’m not sure about Python but in some languages, if developers aren’t careful, import order can change the behavior of a program. …
user1118321's user avatar
  • 4,981
3 votes

Name and code to space between lines/paragraphs

There are a number of terms that might be what you're looking for. It's hard to tell from your description, but here are some suggestions what to search for: Leading - AKA Line Spacing - This contro …
user1118321's user avatar
  • 4,981
4 votes

Fastest way to find all numbers with digits

Set intersection is definitely a possibility. Another method is to use a bitfield to describe which digits are contained in a number. Then you can do a simple logical operation and compare. For exampl …
user1118321's user avatar
  • 4,981
2 votes

Programming cleanly when writing scientific code

Recently, I've started working on some python scripts for a side project. They are a few dozen to a few hundred lines at most. Out of habit, I committed my scripts to source control. …
user1118321's user avatar
  • 4,981
1 vote

Refactoring of a client API for avoid duplicated code and unclear passage of parameters

I would reconsider using a dictionary (hash, map, whatever your language calls a set of key/value pairs) for the arguments. Doing it that way makes it impossible for the compiler to check whether a ca …
user1118321's user avatar
  • 4,981
3 votes
Accepted

How to choose the most suitable solution for a problem given some choices?

You're overthinking it. None of the solutions you've given us is any better than the others given the information we have. This code is small enough to not be worth your time to think about. If this c …
user1118321's user avatar
  • 4,981