[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

Is Python the most versatile language you can learn?

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 60
Thread images: 10

File: pythonlogo.jpg (46KB, 680x459px) Image search: [Google]
pythonlogo.jpg
46KB, 680x459px
Is Python the most versatile language you can learn?
>>
At this point it's probably Javascript.

Python is still a fine language though.
>>
>>59796250
>versatile language

No, Lisp (or Lisp like languages) is the most versatile language.

You can make punch letters machines that read and execute Lisp, or you can write muti threaded elastic enterprise software that servers a billion users on it.
>>
>>59796507
> you can write muti threaded elastic enterprise software that servers a billion users on it.

HAHAHAHAHAH...oh god my sides
>>
>>59796522
worded his claim like a tard, but the claim is true.
>>
File: PortlySinfulDutchshepherddog.gif (2MB, 350x200px) Image search: [Google]
PortlySinfulDutchshepherddog.gif
2MB, 350x200px
dunno what coolaid everyone is drinking but Java is the most versatile at this point

java has the whole android thing going on
its not as easy and speedy as python, but its more versatile IMO

but who the fuck knows what autists around think versatile means.
>versatile
>able to adapt or be adapted to many different functions or activities.
>>
File: 4db.png (60KB, 860x650px) Image search: [Google]
4db.png
60KB, 860x650px
>>59796538
>>
>>59796921
hacker news' site uses lisp to handle all backend work and serves a considerably large audience, Autocad uses its own lisp (autolisp), even the developers of the old Jak and Daxter games use lisp in their development.
>>
>>59797036
Well would you use lisp to code military equipment?
>>
>>59797081
Would you use python?
>>
>>59797150
Yes.
>>
>>59796907
>Java
>not as speedy as Python

wut
>>
>>59797216
I mean speed of development by it
>>
>>59797238
Ah gotcha, I thought you meant speed of execution
>>
>>59796250
Depend on what you mean "versatile".

For me, it is c, c++, since you could use them with nearly everything...
>>
>>59796250
Any Turing complete language, because you can implement other languages on it.
>>
>>59796907
>not as easy and speedy as python
Java is only marginally slower than C++ and faster than python/ruby/JavaScript by two orders of magnitude
>>
Am I not getting the point? For me its clear that op means speed of development (with python you could make a scientific web api with desktop client in less than a week)

If it is "what the language could do given time", well, almost all are turing complete.
>>
>>59797499
>with python you could make a scientific web api with desktop client in less than a week)
With Ruby (rails) in one afternoon.

The general sentiment is true though. With today's hardware very little applications actually need to be programmed in C or C++. Only if calculating power or absolute control of all data is an issue should C be used.
>>
>>59797392
This is basically meaningless, nobody uses rule 110 to program...
>>
>>59796250
http://www.qtile.org/
Best wm is in python
>>
File: hysterical.jpg (10KB, 251x240px) Image search: [Google]
hysterical.jpg
10KB, 251x240px
>>59797427
>Java is only marginally slower than C++ and faster than python/ruby/JavaScript by two orders of magnitude
>my sides are in an infinite loop

Recent code competition...testing submissions...times relative to C:
C# 8x slower
JavaScript 16x slower
Java EIGHTY SIX FUCKING TIMES SLOWER

Whenever I test other submissions Java is inevitably one of the slowest. JavaScript almost always beats it. PyPy will typically beat it. Even interpreted Python can hand Java its ass from time to time. The languages Java consistently out performs are Scala and Haskell, which isn't saying much.

I don't typically see or test Ruby algorithms, so I'm not sure where to place it. But C/C++ are always the fastest, and Java is no where near them.
>>
>>59799391
One more thing: I made note of those differences (8, 16, 86) on a set of submissions where the algorithm used was identical between all four languages (C, C#, JS, Java).

In general it's no surprise to see a C++ solution finish a hard test file in 0.02s while Java takes over a half second or even over a second. In many of those cases I don't study the submissions so you could argue that the Java developer used a worse algorithm, but it's so consistent that Java turning in a time closer to C++ is an absolute shock. So either Java is slow or Java devs are piss poor. Take your pick.

Python is a real odd ball because it's usually slow (but still competitive with Java), but every once in a while it rips through data with a time that's close to C++.
>>
>>59799391
You just suck. What a surprise
>>
>>59799391

source on this?
>>
>>59799502
You're 5yo.

>>59799535
There's not a "source", I'm reporting what I see at sites like HackerRank where challenges have time limits and you can see/test other people's solutions once you've solved a problem.
>>
File: 1490809955947.gif (2MB, 350x305px) Image search: [Google]
1490809955947.gif
2MB, 350x305px
>>59797626
>python2
>>
What are some good books for learning Python?
>>
No.

>>59796907
>speedy as python
It is several orders of magnitude faster
http://benchmarksgame.alioth.debian.org/u64q/python.html

>>59797427
>Marginally slower
http://benchmarksgame.alioth.debian.org/u64q/compare.php?lang=java&lang2=gpp

>>59797499
Speed of development is literally irrelevant for anything other than short scripts.
If it takes me 2 hours to fucking execute the code and crunch all the data I needed it to, it doesnt matter if it only took me 2 minutes to write it. It's a worthless program.

>>59799747
I sincerely encourage you to learn a language that does not have so many memory problems, bad syntax choices, inconsistency between versions, and general idiosyncrasies that WILL make you a bad programmer.
Otherwise, https://www.learnpythonthehardway.org/
>>
File: 1476872427688.png (96KB, 382x491px) Image search: [Google]
1476872427688.png
96KB, 382x491px
>>59796538
Even erlang takes over a second to send a message to 300,000 concurrent connections, let alone a billion. Python would shit the fucking bed and you know it.
>>
>>59799747
humble bundle
>>
>>59799796
>>speedy as python
>It is several orders of magnitude faster
I was talking about speed of development, rapid development...
but I see why everyone jumped on my retarded word use
>>
>>59799742
aka the best python
>>
>>59799742

Welcome to the real world. Basically every professional who uses python is stubbornly hanging on python2.7 still.
>>
>>59799991

besides library support, what makes python 2 better?
>>
File: 1450827938864.gif (987KB, 500x271px) Image search: [Google]
1450827938864.gif
987KB, 500x271px
>>59799991
>>59800037
err, calm your tits
I should have too
I went for qtile-git on AUR and its python2

but the default package just qlite is python3
and theres qlite-python3-git too

considering python2 loses support in 3 years... yeah, good like trying to stick with it

>>59800058
nothing if you ever had to deal with unicode
>>
>>59799822
>I was wrong, I meant another thing!
Doesn't matter, I address that stupid fucking argument too.
Speed of development is irrelevant.
>>
>>59800058
rose colored glasses and old cocks
>>
File: 1489750269617.gif (497KB, 245x200px) Image search: [Google]
1489750269617.gif
497KB, 245x200px
>>59800108
yeah I realized after that if aspie went and reacted to 4 others comment he read my reply what I meant too and just waned to talk argument

>Speed of development is irrelevant.
kek
>>
>>59800037
>>59799991

>tfw i got a master's degree, wrote my side gig/startup's back end web code, and got a 90k/y "data science meme" job using python3
>>
>>59799816
Ooh neat. These books any good though? Which or these are worth getting though? Who the fuck needs 12 beginner books?

>>59799796
What's the alternative to Python you recommend anon?
>>
>>59800143
>I am legally retarded
>>
>>59797203
>compute missiles target
>...
>...
>2018-06-03 : missile launechede
>>
>>59796250
Versatile ? Obviously a Lisp language. You can literally build your own syntax for your specific problem.
>>
>>59799822
>>It is several orders of magnitude faster
>I was talking about speed of development, rapid development...

But that's not true either. I've done projects in multiple languages and Python is not at the top of my list in terms of rapid development.

EVERY high level language claims "hurr durr productivity." And Silicon Valley eats it up because "herp derp we don't have enough programmers", which really means "management wants us to build complex technology products with no staff so management bonuses go up."

But I'm not aware of any good studies on actual, real world productivity between languages. Going off my own experiences, developer ability and familiarity with the problem and tools dominate dev time. If you could equalize that, there's not a clear ranking of languages in terms of dev time. It often comes down to which language has a set of classes or library functions that come closest to solving the problem you want to solve without being tedious to use.

In other words: are you building something from pre-fab blocks are are you mixing your own cement?

People tend to pitch the one language they know (bahbee's first language) or the language with the framework that most closely matches the work they do day-to-day. If you're doing scientific data analysis, Python probably is faster (dev time) than Java or C++. If you're accelerating low level string manipulation, Python sucks in all respects.

tl;dr - use the right tool for the job. (Which is almost never Java.)
>>
>>59799796
>Speed of development is literally irrelevant

Are you serious? Man hours required is literally one of the most important if not the most important aspect of modern programming. It's why 4th generation languages have been supplemented with code generators and massive numbers of open source libraries. Python has weaknesses, but it's a very powerful scripting language that can make lots of things really easy.
>>
>>59801429
Because /it is irrelevant/
Competency and literacy with the language removes that barrier almost completely. What takes somebody 15 minutes to write in python might only take somebody 20 minutes in C#, or hell maybe even less than Python because of LINQ.
The problem is that people use Python inappropriately constantly because LMAO SO EASY TO WRITE IN XDDD without giving consideration to actually execution time.
Python fits in between "simple bash script" and "anything that needs to crunch data", but everybody decides to make it deal with data directly because they're idiots.

It is impossibly slow, it teaches you horrible habits, and it's not compatible between its own versions. It is a shitty language through and through that has such a narrow use case that it shouldnt have any of the popularity it does.
>>
>>59801463
>impossibly slow
so use pypy you dumb fuck
>>
>>59801463
>It is impossibly slow, it teaches you horrible habits, and it's not compatible between its own versions. It is a shitty language through and through that has such a narrow use case that it shouldnt have any of the popularity it does.
It's extremely readable, has probably the most libraries of any language, and it's memory safe. There's a reason the top tech companies do a majority of their engineering in python. Computational time has been decreasing in price, while developer time has not.
>>
>>59797392
So ant farms then? Ant farms are Turing complete.

>he doesn't make sure his computer is hydrated and well fed.
>>
File: c.png (15KB, 367x355px) Image search: [Google]
c.png
15KB, 367x355px
>>59800401
>But I'm not aware of any good studies on actual, real world productivity between languages. Going off my own experiences, developer ability and familiarity with the problem and tools dominate dev time. If you could equalize that, there's not a clear ranking of languages in terms of dev time. It often comes down to which language has a set of classes or library functions that come closest to solving the problem you want to solve without being tedious to use.

Programmers working with high-level languages achieve better productivity and quality than those working with lower-level languages. Languages such as C++, Java, Smalltalk, and Visual Basic have been credited with improving productivity, reliability, and comprehensibility by factors of 5 to 15 over low-level languages such asassembly and C (Brooks 1987, Jones 1998, Boehm 2000). You save time when you don't need to have an awards ceremony every time a C statement does what it's supposed to do. Moreover, higher-level languages are more expressive than lower-level languages. Each line of code says more. The [following table] shows typical ratios of source statements in several high-level languages to the equivalent code in C. A higher ratio means that each line of code in the language listed accomplishes more than does each line of code in C.

https://blog.codinghorror.com/are-all-programming-languages-the-same/
>>
>>59801463
>Competency and literacy with the language removes that barrier almost completely.
Yes.

>>59801545
>It's extremely readable,
"Readable" is entirely dependent on how familiar you are with the language AND how well the programmer wrote the algorithm. I've seen plenty of Python that's less readable than well written C.

>has probably the most libraries of any language,
LOL

>and it's memory safe.
No such thing.

>There's a reason the top tech companies do a majority of their engineering in python.
[CITATION NEEDED]

>Computational time has been decreasing in price,
Moore's Law has been dead since at least 2011.

>while developer time has not.
"hurr durr management needs moar bonuses"

I hate that the industry is driven by memes like this. I hate that in many cases a web page now takes more memory and CPU time than an entire fucking OS from the 80's.
>>
>>59800401
ignore this post
person hasn't used python
>>
>>59801678
>Programmers working with high-level languages achieve better productivity and quality than those working with lower-level languages.

Holy fuck did you even read the blog post? He DISPELS this myth along with the pic you attached. Fucking hell man, don't cite a blog post or paper unless you've READ IT.

From his blog post:
>The main work loop, if considered alone, is almost identical in every language!
> So then, if language isn't the real difference, what is? That very same language comparison paper offers this insight:
>"For all program aspects investigated, the performance variability that derives from differences among programmers of the same language -- as described by the bad-to-good ratios -- is on average as large or larger than the variability found among the different languages."

Odd...that's what I said here: >>59800401
>Going off my own experiences, developer ability and familiarity with the problem and tools dominate dev time.

He also ends the article with:
>.. maybe all modern programming languages really are the same.

I wouldn't go that far. But once again:
* Developer skill+familiarity dominates dev time.
* If you can equalize that, the language with frameworks and libraries which come closest to solving your particular problem is the most productive.
>>
File: b67.jpg (70KB, 600x826px) Image search: [Google]
b67.jpg
70KB, 600x826px
>>59801856
Ignore this post. Poster is a dog and dogs can't program in any language.
>>
>>59800401
This.

/thread
>>
There isn't much you can't do with Java or C# theses days honestly, even with Pypy + C extensions Python is still ungodly slow.
>>
>>59799806
>Python would shit the fucking bed
Right, we're talking about Lisp.

Also, obviously a billion was hyperbole. Lisp is very performant. Check out SBCL -- the quality of the machine code it generates is outstanding.
>>
Yes.
>>
>>59802215
I've heard LispWorks is amazing.
Thread posts: 60
Thread images: 10


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.