Top "Code-readability" questions

Code-Readability is how easy it is to understand a piece of code.

`if key in dict` vs. `try/except` - which is more readable idiom?

I have a question about idioms and readability, and there seems to be a clash of Python philosophies for this …

python idioms readability defaultdict code-readability
How do I align/format code in Android Studio?

Is there a way/shortcut/built-in feature that can align code for operands, like '=' signs? For example, there …

android-studio code-formatting code-readability
Is using java Map.containsKey() redundant when using map.get()

I have been wondering for some time whether it is allowable within best practice to refrain from using the containsKey() …

java performance code-readability map
How to deal with Pylint's "too-many-instance-attributes" message?

I have just tried to lint some code with Pylint, and the last remaining error is R0902: too-many-instance-attributes (8/7) I understand …

python instance-variables pylint code-readability code-structure
Studies on optimal code width?

If you enable the "View Right Margin" in your IDE of choice, it is likely that it will default to 80 …

code-readability
Code-style for indention of multi-line 'if' statement?

When indenting long if conditions, you usually do something like this (actually, PyDev indents like that): if (collResv.repeatability is …

python coding-style indentation code-readability
How to make SQL query more readable in PHP?

When you have a long fields in SQL query, how do you make it more readable? For example: public function …

php mysql readability code-readability
What is Cognitive Complexity in sonar report?

Now a days i switched to sonar reports for static code review and performance improvement. Under the rules section I …

optimization kotlin sonarqube code-readability
A better way to test the value of an Option?

I often find myself with an Option[T] for some type T and wish to test the value of the …

scala option code-readability