[a / b / c / d / e / f / g / gif / h / hr / k / m / o / p / s / t / u / v / vg / vm / vmg / vr / vrpg / vst / w / wg] [i / ic] [r9k / s4s / vip] [cm / hm / lgbt / y] [3 / aco / adv / an / bant / biz / cgl / ck / co / diy / fa / fit / gd / hc / his / int / jp / lit / mlp / mu / n / news / out / po / pol / pw / qst / sci / soc / sp / tg / toy / trv / tv / vp / vt / wsg / wsr / x / xs] [Settings] [Search] [Mobile] [Home]
Board
Settings Mobile Home
/g/ - Technology


Thread archived.
You cannot reply anymore.


[Advertise on 4chan]


File: pyjeet.png (250 KB, 718x588)
250 KB PNG
>Does everything wrong
>wins
Can i book a one way ticket to the next inhabitable planet far away from low iq pyshits and webshits for a glimp of sanity ?
>>
>>108887971
____You didn't start your post withh an indent so I can't read it sorry lol.
>>
I like Javascript/Typescript to be honest
>>
>>108888127
Unironically js is a billion times better than pyshit. However, typescript doesn't actually really improve anything on modern js and is sometimes a disadvantage for some use cases. The muh type muh typescript cult is really annoying. Still, typescript is not annoying enough to detract too much from this.
Still a shitlang that I'd rather have nothing to do with. But we can all safely say: "at least it's not python".
>>
>>108887971
python brainwashed people it's good for math because it has bignum built in. just add huge numbers and it doesn't become 1.51e+69
>>
>>108888307
No, nobody has ever thought that. People use it because pytorch (formerly in lua, it was actually way nicer to use with lua by the way), theano and tensorfl*w, numpy, scipy and scikit-learn, etc.
>>
>>108888410
and before pytorch and numpy there was math.
>>
>>108888424
And before numpy and pytorch nobody used python
>>
I just like it because i can edit the code before running it and i dont need a compiler
>>
>>108887971
The vast majority of python devs I know are also apple users. Another thing Apple ruined.
>>
It’s fine for throwaway scripts or small applications, but fucking retards build 250k+ lines monstrosity that are impossible to maintain with it. Type hinting is near useless, exceptions are fucking retarded, its dog shit slow, async/await is fucking dumb (oh man I just love having to maintain a sync and async version, very cool) etc.

I’ve used Go at work in the past and use it for my personal projects and spend exactly zero time fighting the language or having it blow in my face at runtime.

>>108888177
I’ve tried TrannyScript several times, but always end up rage quitting at the over 9000 compiler errors, 30% more code that doesn’t really help you and all the fucking configs, settings and other shit you need to get it to work and then it doesn’t. It’s exactly like Python for me, fighting the language instead of getting shit done. JavaScript with its awful ecosystem is still less of pain.
>>
>>108888467
you're being deliberately obtuse. authors of numpy and pytorch thought it was a good idea to build on python.
>>
>>108888524
Nope. The authors of numpy wanted to move from matlab. They rightfully thought matlab was shit, not that python was good. The authors of pytorch did not like python at all and preferred lua. They were forced to go to python because that's where Theano was, and Theano was the de facto tool there. The reason Theano was in python was because it was thought by the LISA (former MILA) that researchers would have an easier time learning python than sepples or similar (of course they were right).
>>
>>108888509
In TS/JS, you're not supposed to write any of the config, but rather use generators to write them for you. For example you will do npm init, or maybe npx create-react-app, or something similar. This will set you up. Then you will do something like npm install <something> to update the package and package.lock instead of manually setting it up.
It is a sign of bad design, papered over by tools. But it's still better than the absolute state of pyshit. But it's a good point that typescript is a pain in the ass to setup right anyway, notably when setting up shortcuts like @ paths which somehow never works right.
>>
>>108888177
They are both garbage but Python is at least good for its intended usecase.
>>
>>108888582
No, it's beyond terrible for its intended usecase. It was designed to be an easy to use general purpose high-level language, it was not designed to be a glue language or for small script. That was a niche it was used for later because that's all it's acceptable for (i.e. "better bash"). Meanwhile javascript was intended as a language for interactive contents on the web, and there is nothing else allowed, so by definition it is perfect for its intended purpose.
>>
>>108888467
Not true. Python has grown very consistently and steadily in popularity for the last 25 years.
>>
>>108888595
Python was absolutely desgined as a scripting language, moron.
>>
Python lets you write pseudocode and it just werks like you wrote actual code. That's a huge win for laziness. Of course it was going to win.

But we can turn pseudocode into C trivially with LLMs now, so that makes me wonder what the future of Python is
>>
>>108888601
Popularity is almost an anti-signal for quality or fit of purpose.

>>108888612
>I know better than Guido what python was made for!111
Are you for real
>>
>>108888614
Yeah it's an interesting question. But I think you'll see Python to Go a lot more than Python to C.
>>
>>108888614
python turned into a steaming shitpile when they started version 3. not because they didnt have legitimate problems to address, or because they broke backwards compatibility in a terrible way, but because thats when they forced the competent core devs out in favor of bluehairs and started saying yes to every hairbrained idea. python is quickly catching up to c++ in terms of retardation.
>>
>>108888630
Python was designed to script Amoeba, a distributed OS research project, quickly moved into being a perl alternative for unix scripting. Whatever marketing gossip is filling your fembrain isn't relevant.
>>
>>108888646
>guido doesn't know what he made the language for!!11
The absolute state
>>
>>108888646
if everyone is being intellectually honest we can agree that perl is fucking awful and needs to be destroyed and the ashes diarreha'ed upon
>>
File: file.png (29 KB, 580x455)
29 KB PNG
>>108888601
No, I don't know why the graph axes are like this. But as you can see, until google adopted python in 2005, it had no real userbase at all. Even then it only became very popular after those tools.
>>
>>108887971
Python is flawed, but it just works.
>>
>>108888684
this graph makes me rationally angry
>>
>>108888690
It doesn't work at all, except as a shell replacement. It's quite OK for this, but has a lot of flaws. For example, in that use case, why the fuck do you have to import sys, os and math and all that, when it should be part of the default namespace.
>>
>>108888646
https://www.youtube.com/watch?v=J0Aq44Pze-w&t=6s
The video of Guido van Rossum explaining in an interview that python was developed as a language that mixes the advantages of C and shell without the disadvantages of either for the sake of general use/productivity on any project. The only relationship at all to Amoeba is that in this project, they mixed shell scripts and C programs, and so he was exposed to the disadvantages of both. It was never designed to script Amoeba.
Don't ask chatgpt what to think next time.
>>
>>108888736
if it bothers you that much, from sys import *. but if youve been programming for more than 3 months youll know to not do that
>>
>>108888857
That's not my point. My point is that you have to do from sys import * or import sys in the first place. You shouldn't need to. For the sake of scripting, you basically always want these capabilities.
Even in C you don't need to import anything to get argc and argv.
>>
>>108887971
Don't go anon. That planet is where the aliens dump their old laptops, and they can only run webshit.
>>
>>108888736
You don't have anything interesting to do.
>>
>>108889017
If I didn't have anything interesting to do, python could be suitable for my use.
>>
File: users_over_time_fixed.png (18 KB, 455x580)
18 KB PNG
>>108888695
Yeah it's kinda sickening, but I fixed it
>>
>>108887971
>Does everything wrong
it does the only thing that actually matters in 95% of cases right. being fast and easy to read and write
>>
>>108890387
Only applicable for tiny scripts. It very quickly becomes unreadable especially if you follow their retarded ideas, like greatly preferring list comprehension over loops.
>>
>>108890445
>tiny
No, more than tiny.
But still best in the general domain of scripting and glue, not full applications especially interactive gui apps.
>>108890445
>It very quickly becomes unreadable especially if you follow their retarded ideas, like greatly preferring list comprehension over loops.
List comprehension are no harder to read than for loops until they get complex. But they shouldn't always be used. Nor is common to recommend listcomps over for loops. Listcomps are recommended over map(), reduce() and filter(). Though the last time I checked, map() was still more performant.
>>
>>108890699
>in the general domain of scripting and glue
No.
Lua is far superior for general scripting and glue, as are many other options. I would even dare advance that js with node is better for general scripting than python. You have to really stretch the definition of full applications to make your claim work.
> until they get complex.
That's the point.
>But they shouldn't always be used. Nor is common to recommend listcomps over for loops.
Both false according to pyshit style guide. Furthermore list comprehension is usually considerably faster than for loops, similar to how python code inside a function where the function is then called right away is far faster than writing the code on the top level.
The only way map is faster is when you get gains from lazyness or when you can map some classes of non-anonymous function.
>>
>>108890445
>list comprehension
>unreadable
tell me you haven't actually used python without saying so

I've written hundreds of kloc of python, c++, c# and c, it's a perfectly functional programming language for basic linux software that you only intend to use in specific, predictable deployment scenarios. The problems start if you want need high performance or cross platform portability with lots of dependencies.
>>
>>108887971
good morning sir
how to become weapon of python asap
>>
>>108890824
stfu nigger come back after you've actually written python code for a few years. the language has many issues, as do they all, but you're talking about irrelevant babby shit that doesn't matter
>>
>>108890824
>Furthermore list comprehension is usually considerably faster than for loops,
Only if you're building a list manually with append. If you're just running some operation in a loop then a for loop will be as fast or faster.
>>
>>108887971
Man i wish we could use python at work
>t php dev
>>
File: 1770868442245007.jpg (63 KB, 700x646)
63 KB JPG
>>108888127
I hate JavaScript to an unreasonable degree and I genuinely think I'd rather stock shelves at Walmart than receive 6 figures to write JS.
>>
>>108893271
Whats so bad about it? The tooling around it sucks, sure but there are worse. The language itself is just a dynamic lang with c like syntax
>>
File: Python.jpg (39 KB, 480x360)
39 KB JPG
>>108888682
W00t W00t they still use that junk ?
Python is the same performance wise
>>
>>108893282
My problem is basically the tooling around it, as well as the few bits of random jank that it also has.
There probably are languages with worse tooling, but I uniquely hate the way in which JavaScript's tooling sucks.
>>
>>108888127
typescript is an admission that javascript (and dynamic languages in general) are a failure
>>
>>108893135
>>108892143
>>108892124
Funny how pyshit advocates clearly haven't ever used python in the real world. Coincidence?
>>
>>108893670
Your ilk acts as if js is the only dynamic language in the world. Js is not just dynamic, it's also weak. Weak typing is shit, and everyone has known that for ages. But not only is there no evidence that there is a productivity or bug density difference between dynamic and static languages regardless of program size, it is well known that dynamic languages are better for small prototypes. The only argument would be performance by ts doesn't help there (on the contrary) so that isn't applicable here.
The only thing ts is an admission to is that cargo culting exists everywhere all the time.
>>
>>108893614
Javascript tooling is optional. 99% of the tooling is retarded bloat.
>>108893670
You're just admitting you don't understand the difference between programming and scripting. Scripting requires functional typing not static typing and these clowns who don't know the difference between programming and scripting created TS. Thanks for letting everyone know how low IQ you are.
>>
>>108893861
>Javascript tooling is optional. 99% of the tooling is retarded bloat.
Go write a package.json from scratch using one of the gay frameworks around instead of using generator tools.
Create dynamic elements by hand instead of using jsx, go ahead. Especially in more complex setups.
Or how about you manually bundle your application.
>>
>>108893874
I do manually bundle my own applications. I have my own framework, debugger, code profiler, and database engine written in JS. You're just lazy.

.t been writing JS since 2001.
>>
>>108893898
>all those tools are useless
>which is why I made shitty copies of all those tools
Self-pwn
>>
>>108893910
My tools do all the things that these other tools don't do. I haven't shipped a bug into production since 2013. My interfaces run at 60-120 fps stable. Your shitty community tools struggle to hit 2fps on the interface and take minutes to build. My apps take 200-300ms to build. So yeah, I totally pwned myself.
>>
>>108893935
Thanks for proving you have no clue how web technologies work and you are just making shit up as you go. Good on you to self-pwn a second time.
>>
>>108893954
>web technologies
HTML -> CSS -> JS
V8 -> Blink -> PostgreSQL -> nginx
You probably don't even know what an event loop is or how to call stack is handled and juggled. You'd rather have someone else figure out the fundamentals for you so you can write your shitty little components because that's as much detail as your brain can handle. I'm happy for AI to replace all you do nothing fucks.
>>
>>108894007
Thanks for proving your cluelessness. By the way, this is an 18+ site. You're not allowed to be here, timmy.
>>
>>108894052
TS and React was built as training wheels for shitskins like you because you have low IQ and zero craftsmanship. Literally a million monkeys sat in front of keyboards.
>>
>>108890824
>lua is better
No, different. Python is better for most general purpose scripting, but Lua is better for gaming (or if you otherwise need a simple, minimal runtime.)
>>
>>108894890
Not at all. Lua is better for general purpose scripting. It detects more code issues before the code actually runs, it is far faster with e.g. luajit (which matters even for scripting in practice, e.g. processing data possibly scraped from a website does take time, and bulk operations, which are the domain of scripts, often live or die by the speed of the tight loop), and it has more sensible abstractions for improved readability and writability for most things.
The fact it's easier to embed (hardly only for games, it's also used in operating systems like netbsd, databases, 3d software, text editors...), which allows your scripts to be integrated and migrated more easily as requirements change.
>>
>>108894922
Again you're just fixated on a small domain of embedded scripting engines(haproxy is another one you didn't list), strongly suggesting you have no personal experience and are just parroting flamewarrior bs you heard online. (Because Python is so absurdly popular and Lua isn't)
>>
>>108895041
>get btfo
>no argument
>n-no u d-don't code because u jus dun ok
>unironic appeal to popularity
The absolute state of pyshitters
>>
>>108894922
luajit is truly the secret weapon of programming languages. iykyk
>>
>>108888127
JavaScript is king
>>
>>108888509
>>108888632
How quick is it to pick up Go from Python?
I'd like to move to a compiled language with proper typing

Only thing keeping me with python is that I've mainly focused on data engineering (which is mostly switching to SQL or low code), and python has a library for anything
Does Go have an equivalent to pyproj (which is a package for map projections and coordinate conversions)
>>
I fucking hate Python, so goddamn much.
But if you, like me, hate it enough but still find it useful, at least use Bython and save your sanity.
Fuck that retard and his shitty tabs, you will accept my way and only my way of formatting code, go climb a wall of dicks
>>
>>108895538
>Python, but with brackets
No
>>
>>108887971
why is it always broken, no matter what script you run it will always crash because of some random thing, a hello world crashed to me, a hello world!! because the environment path had python 2 instead of 3 or whatever
>>
>>108888614
who is that retarded to write pseudocode anyways
>>
>>108895667
My favorite part is the random segfaults it gives in wsl2 lmao
>>
>>108890824
>Furthermore list comprehension is usually considerably faster than for loops
Is that true anymore?
With 3.14 I've got for loops quicker than comprehensions


size = 100_000_000


def normal_list(list_length: int):
new_list = []
for n in range(list_length):
new_list.append(n ** 3)
return new_list


%timeit normal_list(size)


def list_compre(list_length: int):
new_list = list([n ** 3 for n in range(list_length)])
return new_list


%timeit list_compre(size)


def declared_list(list_length: int):
new_list: list[int | None] = [None] * list_length
i = 0
for n in range(list_length):
new_list[i] = n ** 3
i += 1
return new_list


%timeit declared_list(size)

For a normal loop I got
6.23 s ± 33.3 ms per loop (mean ± std. dev. of 7 runs, 1 loop each)

For a comprehension I get
6.68 s ± 64.3 ms per loop (mean ± std. dev. of 7 runs, 1 loop each)

And for predeclaring the size of the list I get the quickest of
5.97 s ± 61 ms per loop (mean ± std. dev. of 7 runs, 1 loop each)
>>
python is good because only high caste indians are allowed to use it
>>
>>108897218
based pythonic sir
python is for aryan brahmins
c is for untermensch dalits
>>
>>108895665
cope
>>
>>108893861
>the difference between programming and scripting
There is no objective difference. Any distinction between the two definitions is completely arbitrary.
>>
>>108887971
Python is a brahmin language.
Real dalits use java or C
>>
C# is unironically better than Python and Jslop combined, you won't ever touched it because it was microslop invention, if it was google y'all would worship it.
>>
>>108900432
>if it was google y'all would worship it.
Google made Go and I hate it



[Advertise on 4chan]

Delete Post: [File Only] Style:
[Disable Mobile View / Use Desktop Site]

[Enable Mobile View / Use Mobile Site]

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.