4 ms·
I have fond memories of using Python 8-10 years ago, but looking at it today, I'm not sure I see compelling reasons not to just use C# instead. I can have real
by douche 11y ago
I have fond memories of using Python 8-10 years ago, but looking at it today, I'm not sure I see compelling reasons not to just use C# instead.
I can have real static typing if I want it. I can also have dynamic typing if I want that. I can use lambda functions. I have LINQ. I can use ScriptCS or some of the new Roslyn stuff if I want to use it as a scripting language. Unix support is not as great, but they are coming along with that. There's no GIL.
Is there some killer feature for Python that I'm overlooking?
- ubernostrum 11y agoStill less boilerplate than C#. Still on average more concise to express the same idea. Standard library is a nice mix of function-based vs. class-based solutions where appropriate, rather than forcing OO on you even when it's not the ideal approach. Cross-platform C# usage is still not even a reality, let alone as good as what Python already has. In several domains of programming, Python has best-of-breed, and sometimes just flat-out the best, available libraries.
- vpkaihla 11y agoCompared to C#, it doesn't require you to run Windows in production.
- muaddirac 11y agoI think its ubiquity is important (installed by default on most non-Windows machines, at least in my experience) combined with the simplicity of running a python script. Now that Microsoft is supporting non-Windows with .Net core, C# is more attractive. That said, if I was thinking compiled Python with static typing my mind would go to Go. Lots of options!
- moonchrome 11y agoThe only domains python and C# really overlap is web with ASP.NET and Python web frameworks - and here portability used to be the determining factor. Python use cases are completely different from C# - Python is all about fast iteration and prototyping, REPL, interfacing to native libraries etc. C# is about static typing and all that it implies. F# is slightly closer to Python with REPL and type inference but still on the C# side of spectrum.
- spooningtamarin 11y agoNim has much easier syntax than C#, why not that instead, has better type inference than C# too. Pythonesque in its core.