Click here to Skip to main content
15,911,711 members

Welcome to the Lounge

   

For discussing anything related to a software developer's life but is not for programming questions. Got a programming question?

The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.

 
GeneralRe: Why this sudden hype for Python? Pin
Leng Vang4-Oct-17 6:28
Leng Vang4-Oct-17 6:28 
GeneralRe: Why this sudden hype for Python? Pin
W Balboos, GHB3-Oct-17 0:31
W Balboos, GHB3-Oct-17 0:31 
GeneralRe: Why this sudden hype for Python? Pin
Slacker0073-Oct-17 1:42
professionalSlacker0073-Oct-17 1:42 
GeneralRe: Why this sudden hype for Python? Pin
Michael Breeden4-Oct-17 1:50
Michael Breeden4-Oct-17 1:50 
GeneralRe: Why this sudden hype for Python? Pin
Nathan Minier3-Oct-17 1:45
professionalNathan Minier3-Oct-17 1:45 
GeneralRe: Why this sudden hype for Python? PinPopular
Marc Clifton3-Oct-17 2:08
mvaMarc Clifton3-Oct-17 2:08 
GeneralRe: Why this sudden hype for Python? Pin
sir_download_alot3-Oct-17 22:20
professionalsir_download_alot3-Oct-17 22:20 
GeneralRe: Why this sudden hype for Python? Pin
atali4-Oct-17 5:10
atali4-Oct-17 5:10 
Syntactically Python is one of the worst languages that are developed recently. Maybe there are others like that, I don't know. This is one of the languages where 'nothing' matters, as in white spaces define the structure of the program. Code reviews are made almost impossible because instead of answering a question 'is the program structure as-is correct?' you need to answer a question 'which of all possible structures would be correct?'. Simple yes/no becomes 'design same program that you're reviewing on the spot and see if you come up with same result'. Example:
if (x)
        something()
        somethingelse()

Should somethingelse() be indented like this? If that code is already indented by 5 levels, maybe somethingelse() needs to be pulled back one level? two? three? People can't indent properly in languages where indentation is not important (curly brace languages, for example), and you'd expect them to indent something correctly where it is important?

The initial hype came by showing: look, it's simple, i type '2+3', it prints '5'. An over-glorified calculator. Next, they print 'hello world' and see on console 'hello world', and it only takes one line of code instead of 10. Great. It makes simple things simpler and hard things almost impossible.

There are tons of libraries written in Python, but i haven't seen data about how efficient Python is for developing these libraries, as opposed to some languages with static typing.

Less lines of code does not mean it is overall efficient. Look at code golf on Stack Overflow, they solve small but relatively complex problems there using programs written with 10-20 Unicode characters that are incomprehensible for most developers.

Writing a program is about 10% of the effort, maintaining it is another 90%, and languages should be such that maintenance is easier. Maintenance is not 'figuring out what the program does'. That part is trivial, run it through debugger with single-stepping and you see what it does. Maintenance is like any other reverse engineering, where you try to 'figure out what the developer was thinking when they developed that program'. With the example above it is not possible to say for sure if somethingelse() was thought of being part of that condition block or not. You'd need to reverse engineer the entire algorithm in that function, then think if you'd do it in the same way, and if you disagree, you'd do it differently, probably introducing more bugs because you don't have any guidance about original thinking. There are too many paths through the code where the implementation can get forked by indentation errors, each line after the first one in if() statement should be questioned if it has proper indentation. If {} are around the block, you can auto-format the code to make it readable and then look at the algorithm on single path and check it for correctness. It is less likely to place somethingelse() erroneously inside or outside a block than to indent it by incorrect number of spaces.
GeneralRe: Why this sudden hype for Python? Pin
swampwiz4-Oct-17 19:14
swampwiz4-Oct-17 19:14 
GeneralRe: Why this sudden hype for Python? Pin
Marc Clifton8-Oct-17 2:46
mvaMarc Clifton8-Oct-17 2:46 
GeneralRe: Why this sudden hype for Python? Pin
atali10-Oct-17 5:05
atali10-Oct-17 5:05 
GeneralRe: Why this sudden hype for Python? Pin
jschell4-Oct-17 6:23
jschell4-Oct-17 6:23 
GeneralRe: Why this sudden hype for Python? Pin
Eytukan3-Nov-17 3:27
Eytukan3-Nov-17 3:27 
GeneralRe: Why this sudden hype for Python? Pin
stoneyowl23-Oct-17 2:41
stoneyowl23-Oct-17 2:41 
GeneralRe: Why this sudden hype for Python? Pin
John Nurick4-Oct-17 0:39
John Nurick4-Oct-17 0:39 
GeneralRe: Why this sudden hype for Python? Pin
Foothill3-Oct-17 4:07
professionalFoothill3-Oct-17 4:07 
GeneralRe: Why this sudden hype for Python? Pin
PIEBALDconsult3-Oct-17 4:13
mvePIEBALDconsult3-Oct-17 4:13 
GeneralRe: Why this sudden hype for Python? Pin
Leo563-Oct-17 20:53
Leo563-Oct-17 20:53 
GeneralRe: Why this sudden hype for Python? Pin
Slacker0074-Oct-17 2:08
professionalSlacker0074-Oct-17 2:08 
GeneralRe: Why this sudden hype for Python? Pin
kalberts3-Oct-17 22:15
kalberts3-Oct-17 22:15 
GeneralRe: Why this sudden hype for Python? Pin
GKP19923-Oct-17 23:18
professionalGKP19923-Oct-17 23:18 
GeneralRe: Why this sudden hype for Python? Pin
Tomz_KV4-Oct-17 2:00
Tomz_KV4-Oct-17 2:00 
GeneralA few reasons Pin
Michael Breeden4-Oct-17 2:00
Michael Breeden4-Oct-17 2:00 
GeneralRe: Why this sudden hype for Python? Pin
Leng Vang4-Oct-17 6:10
Leng Vang4-Oct-17 6:10 
GeneralRe: Why this sudden hype for Python? Pin
jschell4-Oct-17 6:17
jschell4-Oct-17 6:17 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.