this post was submitted on 02 Jun 2023
5 points (100.0% liked)

Programming

3347 readers
1 users here now

All things programming and coding related. Subcommunity of Technology.


This community's icon was made by Aaron Schneider, under the CC-BY-NC-SA 4.0 license.

founded 1 year ago
MODERATORS
 

It seems like there are about ~~22~~ ~~27~~ ~~46~~ ~~219~~ ~~320~~ ~~493~~ 1840 active subscribers here. I have a few questions for you all.

  • Which programming languages do you regularly use?
  • Which are your favorite to work with and why?
  • Which do you have interest in trying and why?
top 44 comments
sorted by: hot top controversial new old
[–] [email protected] 4 points 1 year ago (1 children)

At work it's mostly python, .net core and javascript (regrettably).

Personally, I used to write a lot in C and C++ for embedded, but recently diving more into other areas. Developing quite the love for Golang (GO) and it's simplicity.

[–] [email protected] 1 points 1 year ago

I see a lot of love it or hate it on golang. What do you think drives that?

[–] [email protected] 4 points 1 year ago

I work with C# & TypeScript, which frankly I don't find too bad

I love to work with Scala though, I find there's a really nice way to do almost everything, and C is nice because it allows so much control over what your program is actually doing - same with OCaml really, however the ability to use Java libraries in Scala makes it that bit better

I'd quite like to try Spatial for hardware in the future

[–] [email protected] 4 points 1 year ago (1 children)

Python and C# for the most part. I'm also putting serious effort towards learning Rust, but I likely won't be able to use it at work. It's a good learning experience, and I can tell that my code after learning basic Rust in C# and Python is better than before.

[–] [email protected] 2 points 1 year ago (1 children)

What's better with your code? What did using Rust reach you?

[–] [email protected] 1 points 1 year ago

The "correctness" of my code would probably the greatest single difference I've noticed in my own habits.

For example, I've become very strict with myself about using type hints and relying on appeasing type checkers and such. The way I structure my projects has changed, where I separate functionality from data to a larger degree, mimicking struct and impl where it makes sense to do so. I've pretty much stopped using dict, and rely on dataclasses instead when writing Python. I've given up on forcing everything to be OOP (even C#), which has made my code easier to read and maintain. There are probably other things as well, though I can't list them at the top of my head.

Some of it is probably just good practice, a result of having matured after being exposed to new languages. Some of it probably wouldn't be considered pythonic or idiomatic, but I'm not sure I care anymore. My code is more reliable (and often faster), and that's what matter in the end.

[–] [email protected] 3 points 1 year ago* (last edited 1 year ago) (1 children)

Mostly C++, I develop back-end with algorithms that require all the performance we can get. We 're currently trying Rust for a small project, I hope it will succeed, I definitely love this language. And python when merformance is not the main concern.

[–] [email protected] 1 points 1 year ago

Seems like Rust is popular among C++ developers.

[–] [email protected] 3 points 1 year ago* (last edited 1 year ago) (1 children)

At work I mostly use Matlab and a smattering of C++, at home I'm trying to learn more C++ but prefer to use python. I think my next endeavor will be learning Rust, not sure yet what I'll use it for though.

[–] [email protected] 1 points 1 year ago (1 children)

Everyone tells me that Rust is a good replacement for c++, so maybe whatever you are doing with c++ you can try an implementation in Rust?

[–] [email protected] 2 points 1 year ago

Yeah, that's a great idea. Really interested to see how it goes, heard mixed info back on how easy/hard it is to learn.

[–] [email protected] 3 points 1 year ago (1 children)

My main languages are Ruby and Python (does SQL count?), but I dabble with Javascript when needed.

I have been liking Ruby more and more because of how easy it is to use and the community support it has. I have really appreciated RSpec, and that's the main reason I enjoy it over Python.

I really want to get into Rust because it is so different from Ruby. I am also a strong supporter of adopting a different language if you need to. I am not a fan of introducing types into Ruby or Python because there are other languages that have it built in and also the dynamic nature of those languages are their strengths.

[–] [email protected] 1 points 1 year ago* (last edited 1 year ago)

I could see value in adding type checking to a codebase that is transitioning from exploratory to maturity without having to rewrite in another language.

And of course SQL counts!

[–] [email protected] 2 points 1 year ago (1 children)

@[email protected] Clojure(Script/Dart) is the way, I really want to get into Elixir at some point though!

[–] [email protected] 2 points 1 year ago (1 children)

What got you started with Closure?

[–] [email protected] 1 points 1 year ago

@[email protected] A course in software development got me started with Clojure! At first I hated the language, but it slowly grew on me ​:vibe_cat:​

[–] [email protected] 2 points 1 year ago

C & Postscript. Been using both since the mid-80s. The programming I do for work is CNC related. I don't learn new things.

[–] [email protected] 1 points 1 year ago* (last edited 1 year ago) (1 children)

Regularly use: Common Lisp (SBCL mainly) and Crystal.

Favorite to work with: same as above. They seem to match how I think well, so it's easy to solve problems in them. Their speed is also a nice bonus, as is Common Lisp's debugging and image-based development. I also really like how Crystal feels like a dynamic language (it's very reminiscent of Ruby), yet is still statically typed and compiled.

Interest in trying: m68k assembly for some ungodly reason lol

[–] [email protected] 3 points 1 year ago

Ooh, never heard of Crystal, looks awesome.

[–] [email protected] 1 points 1 year ago
  • I work with Java, but like messing around in C# and Kotlin
  • Definitely Kotlin
  • I'm thinking of getting into Rust or Go one day, because they seem cool
[–] [email protected] 1 points 1 year ago

It's not really a coding language but I use SQL a lot for work. Occasionally Python and R. As you can probably imagine with this list, I'm a data scientist.

My favorite to work with is actually autohotkey, which I use to automate stuff, because it can be a fun little challenge to figure out how to automate based on the system it's running on and what I'm trying to do.

[–] [email protected] 1 points 1 year ago* (last edited 1 year ago)

Regularly Use

  • bash
  • python
  • golang
  • rust
  • elm

Favorite

  • rust because it provides a pretty good expressive type system for letting the compiler keep you honest.
  • elm helps me avoid client-side programming hell with JavaScript.

Interested

  • zig because of its promise of "compile it for anything" and small language philosophy.
[–] [email protected] 1 points 1 year ago

C#, JS, SQL, and (AB) PLC Ladder Logic.

I really like working in the dotnet ecosystem; it's well maintained and supported. I'm fairly weak in JS and find it a bit frustrating at times. Mostly because it seems that packages are obsolete or abandoned by the time I'm done reading the docs. I know enough SQL to be dangerous.

Everyone seems to like Rust, maybe I should see what all the fuss is about.

[–] [email protected] 1 points 1 year ago

C# with Unity. I sometimes write in VB for its form controls or VB/A for its spreadsheet interface.

[–] GPLGang 1 points 1 year ago

F#

It's an ML with top tier tooling

Don't learn it if you don't want to rage at most other languages for ignoring this one simple trick to make error handling 10x better. Or that they have to use classes to describe something like IP addresses

MyWorkHereIsDoneMeMe.png

[–] [email protected] 0 points 1 year ago (1 children)

For work I currently use C and python mainly, and for some personal projects I've been using python backends with JS/Vue frontends.

I really enjoy Python, but as I use it more I've found the quality of the docs to be an impediment. They're hard to reference quickly.

I really want to start using Rust, but it's not really applicable to the kinds of projects I'm currently working on. I've started picking up some Clojure and PHP for two open source projects that I've started contributing to.

[–] [email protected] 2 points 1 year ago

I really enjoy Python, but as I use it more I’ve found the quality of the docs to be an impediment. They’re hard to reference quickly.

this, and the need to understand the wordpress core, pushed me into php long ago; python used to be my primary language.

since about the beginning of the year, php docs now are often behind captchas. i don't know what in my environment triggers them, but i know they trigger me, and so i've been refactoring things back into python. mediocre and accessible docs >> somewhat better docs behind captchas. it's impossible to navigate the changes for change's sake between php 7 and 8 when you keep getting stopped to identify which fuzzy photo is of a dust cloud.

these are my home projects. for work, it's typescript/js/react against java/spring back end. i code mostly the front end now, but since i've also done java, i can make better tickets when there's a back-end problem :)

[–] [email protected] 0 points 1 year ago* (last edited 1 year ago) (1 children)

I teach a class taught in OCaml. Despite that, I don't really like OCaml. It's good for education but IMO not that great for actually using it. My brother works at Jane Street and even he agrees... Like, it's fine, but not great.

Beyond that I make regular use of Haskell and Python for my graduate research and personal projects. I recently took a course in Java, but unless I don't have a choice, I'd rather use Kotlin. I'm also involved in the hardware simulator Turing Complete, so a lot of my side projects lately have been ETCa assembly programs.

I want to learn Rust and Scala, probably in that order.

edit: I also quite like Scheme and I used it for advent of code last year. Unfortunately I don't get opportunities to use it much, but if I ever get to teach a compilers course, I want to try the "reverse nanopass" approach that is currently used, I believe, at Brown University.

[–] [email protected] 0 points 1 year ago (1 children)

I don’t really like OCaml. It’s good for education but IMO not that great for actually using it. My brother works at Jane Street and even he agrees… Like, it’s fine, but not great.

I don't get to converse with a lot of OCaml users. What makes it "not great"? Is it the tooling?

What is your graduate work on?

[–] [email protected] 2 points 1 year ago

The tooling is actually OK, provided you work on Linux. If you work on windows, the tooling is basically telling you to go get Linux.

It doesn't capture a lot of what many functional programmers consider the essence of FP: the language, and the people who use it, actively encourage mutable state in programs, and the type system is not powerful enough to capture useful abstractions like functors (generalized containers) or monads (generalized patterns of computation).

There are also some specific language design decisions that I don't like. For example, this code typechecks:

let id : 'a -> 'b = fun x -> x;;

The 'a -> 'b is a type annotation that says "you give me anything of type 'a (a type variable), and I'll give you back something of type 'b." That's complete bogus - that's not possible. It typechecks because OCaml goes "OK, this is fine as long as 'a and 'b are the same variable," and then for the rest of the typechecking process, that's what happens. id actually gets assigned the type 'a -> 'a. In the best case, this is confusing and occasionally useful to do what other languages do with "type holes." In the worst case, it's actively wrong. Using different type variables in a type can provide static guarantees that some things cannot mix, and with OCaml that is simply not possible for a declaration like this one. You can do it, but with a lot more boilerplate. Compare that to Haskell, where the right behavior is the default, and you can obtain a type hole just by using a variable name that starts with _.

My graduate work is currently on type error provenance. You know some piece of code has a type error, but where is the actual problem? This is a hard problem that compilers are notoriously bad at answering.

[–] [email protected] 0 points 1 year ago (1 children)

Professionally, I mostly use Kotlin, Typescript, and Java.

For fun, I've recently been using BQN, which is quite nice compared to J, which I had been previously using. I also use Elm, Rust, Python and a smattering of others.

[–] [email protected] 0 points 1 year ago (1 children)

The APL family of languages aren't the most popular, but there seems to be cult like followings of each variation.

[–] [email protected] 3 points 1 year ago

Yeah, I think they're just the more vocal subset of users. The same thing happens in functional languages. (Especially Lisp.)

Array languages in general are fun to use because you can express a great deal in very little space. Of course, you have to think more about how to encode something, or even when reading. I feel like those are good muscles to exercise for when you're reading more densely written code in any language.

[–] [email protected] 0 points 1 year ago (1 children)
  • Professionally I mostly work with C (no ++) for bare metal micro-controllers. Basically I'm using it to tie together HW peripherals with some communication library.
  • Python is my one-size fit's all tool for anything that has an OS. Testing, scripting, interfacing, it does it all.
  • I also used to work a bit with Erlang, which is my personal favourite programming language for its pure elegance and resilience.
[–] [email protected] 0 points 1 year ago (2 children)

Mainly JavaScript, typescript, html, and scss. Occasionally bash and groovy. My favorite to work with is typescript. It’s a superset of JavaScript so naturally JavaScript is a very close second. I am interested in ruby and rust. Just because those are the two languages that I have been enamored with in the past so they are the ones that I have spent more free time than any other learning about them and using them for side projects.

[–] [email protected] 3 points 1 year ago

I love Ruby, I wish it were more popular. I'm starting a Ruby + Sintatra project. Your post is making me want to try adding typescript in there.

[–] [email protected] 1 points 1 year ago (1 children)
[–] [email protected] 1 points 1 year ago

Thanks for the suggestion!

[–] [email protected] 0 points 1 year ago (1 children)

I don't have any professional experience or ambitions, but:

Use nim for personal projects. It feels like there is less boilerplate than others I've tried and it felt more natural to me than python. Faster than python and compiles. Plus has a javascript backend option. Pretty neat language all in all and does an ok job from scripting to web.

Interest in trying? Probably Kotlin. Seems like another language with wide utility.

[–] [email protected] 0 points 1 year ago (1 children)

I've only heard of nim thanks to the discourse around Mojo, i'll check it out !

[–] [email protected] 0 points 1 year ago (1 children)

How is nim related to mojo?

[–] [email protected] 0 points 1 year ago (1 children)

There is a perspective that Nim kinda sorta writes/looks like a compiled Python. It also seems to get mentioned everywhere.

[–] [email protected] 1 points 1 year ago

Yeah, it's kind of a pascal/modula/ada thing with a more python like syntax. It does have a really nice typesystem that I enjoy a lot :)

load more comments
view more: next ›