Skip to main content

New answers tagged

4 votes

Cost sharing application in Python

Here I'll talk mostly about the UI and not a lot about Python in particular. Here it is: The colours are... bad. There's a weird mismatched background between teal and grey. There's a more abstract ...
Reinderien's user avatar
  • 62.8k
5 votes

Cost sharing application in Python

Use more special-purpose functions You put quite a lot stuff into a single function (e.g., __init__). You might want to segment your UI into multiple functions or ...
Green绿色's user avatar
7 votes

Typical password generator in Python

Do we really want a password? The question code assumes generation of a generic password, but the underlying intent is to generate an authentication factor. Authentication factors are commonly ...
3 votes

Check for key in dictionary without magic value comparison

message creation This list creation ([...]) is unnecessary in this code: ...
AJNeufeld's user avatar
  • 33.9k
-3 votes

Finding a common prefix/suffix in a list/tuple of strings

...
milahu's user avatar
  • 87
2 votes
Accepted

"Element Fusion" game where 2048 meets Chemistry

The GUI looks great, the game is a lot of fun to play and (unfortunately) it is quite addictive. Bug or feature After playing it a hundred times or so, I began to notice that the game was ending ...
toolic's user avatar
  • 3,942
4 votes
Accepted

Check for key in dictionary without magic value comparison

I think that creating a constant for a dict key of a third-party lib to use in a single comparison isn't good practice. I agree. comment The standard way to model "I disagree with the linter on ...
J_H's user avatar
  • 30.8k
3 votes
Accepted

"Polite" internet connectivity check on separate thread

There are some difficulties with the OP code. The two aspects are: design of service implementation of a given design design abuse of the digital commons This is just not good. It discourages ...
J_H's user avatar
  • 30.8k
6 votes

"Polite" internet connectivity check on separate thread

Why 3 threading.Condition instances? You have defined 3 threading.Condition instances when I believe you could have simplified ...
Booboo's user avatar
  • 1,756
2 votes

"Element Fusion" game where 2048 meets Chemistry

Overview The code layout is good, and you used meaningful names for classes, functions and variables. Documentation The code should have a header comment describing the purpose of the code, such as: <...
toolic's user avatar
  • 3,942

Top 50 recent answers are included