Reddit Programming
190 subscribers
1.22K photos
127K links
I will send you newest post from subreddit /r/programming
Download Telegram
Solving and benchmarking QUBO problems with Gurobi in Python
https://www.reddit.com/r/programming/comments/1vija3m/solving_and_benchmarking_qubo_problems_with/

<!-- SC_OFF -->State-of-the-art classical optimizer Gurobi for Quadratic Unconstrained Binary Optimization (QUBO) problems. The core gurobipy implementation for QUBO is relatively compact: ```python model = gp.Model() x = model.addMVar(n, vtype=GRB.BINARY) model.setObjective(x @ Q @ x, GRB.MINIMIZE) model.optimize() solution = x.X.astype(int) objective = model.ObjVal ``` Complete workflow in Python. First formulate a graph problem (weighted Max-Cut) as QUBO, solve it with Gurobi, benchmark increasingly large instances, and understand what the solver is doing beyond the optimize() call. Interested in feedback on the modeling, benchmarking methodology, and which additional Gurobi metrics would make the comparison more rigorous. <!-- SC_ON --> submitted by /u/Future_Ad7567 (https://www.reddit.com/user/Future_Ad7567)
[link] (https://youtu.be/TB1ny8o4ImQ) [comments] (https://www.reddit.com/r/programming/comments/1vija3m/solving_and_benchmarking_qubo_problems_with/)
Here's why OOP makes a lot of sense to me.
https://www.reddit.com/r/programming/comments/1vikuz4/heres_why_oop_makes_a_lot_of_sense_to_me/

<!-- SC_OFF -->I kind of feel like OOP has a bad rep in the programming community. Personally, after having programmed Java for over 20 years, its object-oriented programming model feels very natural to me. So, I wanted to share how I think about programming, how I translate my ideas and thoughts to code, and why OOP is actually a really nice programming style for me. Perhaps it could help you out too. <!-- SC_ON --> submitted by /u/OSBY_Glabay (https://www.reddit.com/user/OSBY_Glabay)
[link] (https://youtu.be/MAnXlpXpFRQ) [comments] (https://www.reddit.com/r/programming/comments/1vikuz4/heres_why_oop_makes_a_lot_of_sense_to_me/)
DRY vs. SRP
https://www.reddit.com/r/programming/comments/1virrlk/dry_vs_srp/

<!-- SC_OFF -->After re-reading "Clean Architecture" I ended up with some confusion regarding Bob's take on repetition and single responsibility. Ge defines the SRP as a function only serving one actor. Dies that mean, that repetitve code is justified according to him, as long as it serves seperate actors/user groups? I am aware that such decisions depend on the specific situation. I was just wondering if others found the same contradiction, or if i misunderstood it. Thanks <!-- SC_ON --> submitted by /u/TalesGameStudio (https://www.reddit.com/user/TalesGameStudio)
[link] (http://uncle-bob.com/) [comments] (https://www.reddit.com/r/programming/comments/1virrlk/dry_vs_srp/)
Beyond Senior - Creating Hope
https://www.reddit.com/r/programming/comments/1vkdq8p/beyond_senior_creating_hope/

<!-- SC_OFF -->Every time I leave a role I try and write up where my philosophy landed and what I want to take into my next role. Having seen this play out at enough companies over the years to where people progressively lose motivation and stop believing change is possible I've come to the opinion that one of the most valuable things we can do as engineering leaders is to provide hope. The post goes more into it, but I do not mean any vapid rah-rah motivational speeches, I mean earning back that hope every day by snowballing small wins into larger ones and making people believe that their effort matters. <!-- SC_ON --> submitted by /u/keyslemur (https://www.reddit.com/user/keyslemur)
[link] (https://baweaver.com/writing/2026/08/09/beyond-senior-creating-hope/) [comments] (https://www.reddit.com/r/programming/comments/1vkdq8p/beyond_senior_creating_hope/)
The dangers of Postgres subtransactions
https://www.reddit.com/r/programming/comments/1vlm2vs/the_dangers_of_postgres_subtransactions/

<!-- SC_OFF -->Really good article explaining the implementation detail within Postgres regarding subtransactions. Very cool benchmark that I was unaware of <!-- SC_ON --> submitted by /u/Wooden-News-962 (https://www.reddit.com/user/Wooden-News-962)
[link] (https://planetscale.com/blog/the-dangers-of-postgres-subtransactions) [comments] (https://www.reddit.com/r/programming/comments/1vlm2vs/the_dangers_of_postgres_subtransactions/)
Squeak 6.1 (a modern Smalltalk programming environment implemented in itself) was released!
https://www.reddit.com/r/programming/comments/1vlqtmx/squeak_61_a_modern_smalltalk_programming/

<!-- SC_OFF --> After more than 4 years of work, our community has put together a big bouquet of new capabilities and improvements: A new tree browser for navigating and organizing classes Objectland, bringing back and extending the colorful world of examples from Squeak 3 Plenty of new features, bugfixes, and speed-ups for programming tools, the Morphic UI framework, and the rest of the system Original announcement on Fosstodon: https://fosstodon.org/@squeak/117071273007117118 <!-- SC_ON --> submitted by /u/LinqLover (https://www.reddit.com/user/LinqLover)
[link] (https://squeak.org/release_notes/6.1/) [comments] (https://www.reddit.com/r/programming/comments/1vlqtmx/squeak_61_a_modern_smalltalk_programming/)