Devilstower, to random
@Devilstower@mstdn.social avatar

Seems like a good day for a reminder of how quick studios are to screw over writers. In 1999, NBC moved a series from their regular network to Sci Fi Channel. My pay went from $240,000 to $0. Because my contract paid "per broadcast episode" instead of just "per episode."

The series ran. I just got nothing.

HistoPol,
@HistoPol@mastodon.social avatar

@Devilstower

(8/n)

"...broadcast programming substituted for for which requisite or clearances to transmit over the Internet have not been obtained Did your contract even include "new means of transmission, i. e. The [; usually, all uses must be explicitly granted] and one with substitute advertisements, and

(2) An in accordance with 17 U.S.C. 114(d)(2)(C)(iii) of an archived , which program was..."

peterrenshaw, to programming
@peterrenshaw@ioc.exchange avatar

Playing with GTP today & tried to push it.

The objective: from an html page type in a URL, on pressing Go button, extract the video stream, grab the audio and encode to mp3 and play it.

Due to errors in module choice (non existent or old) I had to downgrade my ambitions to a CLI version. I want command line args, so 🤖chose Clap and the code barfed bad (just looking at I know, cause I’ve spent time upgrading from 2.x to 4.x) and understand the code well.

Here’s todays wild ride, when I chided the 🤖 and wrote some example code, mentioned the specific rust module, it re-wrote the Clap code correctly.

Conclusions: Most example rust code seen uses old Clap derive examples. The LLM gas seen the latest version. If you prompt for this, it rewrites it correctly. Learning or being more specific? I lean towards the later. / / / 🦀

joshsusser, to programming

"Composition is better than Inheritance" is already a cliché, and it's usually even true. Today. But it wasn't always the case. Back in the early days of Object-Oriented Programming, computers were pitifully show, memory was tiny, and OOP languages only worked acceptably because of aggressive optimization in implementation.

Inheritance itself is mostly an optimization. (I don't have room for the explanation here, but buy me a coffee and ask me some time.) In Smalltalk-80, sharing behavior by composition was several orders of magnitude slower than inheritance. With inheritance, there was a VM optimization to make it go as fast as possible. But for composition, you had to do all that work in Smalltalk code, which involved message sends, stack frame allocations, and all the rest. Even then, inheritance felt restrictive, and I spent quite a bit of time writing hacks to enable performant compostion by tricking the Smalltalk object system.

Modern object languages don't have to fit within the same restrictions as earlier efforts, and that changes how we design software. Early Smalltalks only supported 16K objects because object pointers were mapped through a fixed size Object Table. Even when we had enough RAM, we couldn't allocate 20K strings! When the first modern "OT-less" Smalltalk appeared with an unlimited number of objects, it changed everything.

OOP is polymorphism + encapsulation + inheritance by class. Of those three, class inheritance is the least critical and the most replaceable. Now that we can enjoy good performance with other kinds of behavioral composition, we can throw off the itchy wool sweater of class-based inheritance.

#OOP #programming #Smalltalk

EvanHahn, to programming
syntaxseed, (edited ) to random
@syntaxseed@phpc.social avatar

❓How do you organize your source #code boundaries?

You have Students. The public accesses them. They CRUD themselves & admins CRUD them differently.

Everything in a students folder?

Or...

students/edit.twig
admin/students/edit.twig
public/students/view.twig

?

Other?

(I lean toward subject/object/verb.twig myself.)

#programming #development

raccoon, to programming

🧵 [1 / 3]

is a fascinating thing from a perspective.

Every part of the the ceremony, as silly as it seems, has, or rather had, meaning. A king's power does not actually come from some mythological deity, but from the support of nobles who would lend the military (and economic) power necessary to enforce his rule. Getting that support, required an aspiring king to play a complex game of flattery, intimidation, backstabbing and promises.

davidbures, to programming
@davidbures@mstdn.social avatar

Man, with the help of @helge, my networking code is so efficient that you can’t see the cool animations I made for the various connection stages, so I had to add a bunch of DispatchQueue.main.asyncAfters just to let the user experience the animations.

Truly suffering from success

thelegendlinux, to rust

Does anyone know of it is possible to dynamically resize a GUI window made with iced? So for example, I have a window at a specific size and I want to resize it in the code when I switch to another view in the application.

pixel, to programming
@pixel@social.pixels.pizza avatar
jeff, to gamedev
@jeff@phpc.social avatar

If you're helping teach a kid to code (or learning yourself), this is a great step-by-step tutorial series for creating a full-featured tower defense game in Roblox w/ Lua.

There's the right amount of iterative progress in each step. The code is clean, and starts very simple with ongoing refactoring to add extensibility.

My 10yo son is really enjoying it. Godot next, but Roblox has a built-in audience that's hard to beat.

https://www.youtube.com/playlist?list=PLtMUa6NlF10fEF1WOeDtuGcIn0RdUNL7c

thomasreggi, to programming

Who is someone you follow on mastodon that is a programmer and posts regularly about new technologies? Looking for people to follow.

janriemer, to programming

No, do NOT understand your code.🙄

davidr, to programming
@davidr@hachyderm.io avatar

You know that thing where you find old of your own and marvel at how stupid you used to be?

I just had the opposite. "Wow, this is a good idea. Hey, that was my idea!"

What a warm and fuzzy feeling! I've grown as a professional!

Except wait. This means my peak is behind me. I'm on the down slope. These are my declining years!

Soon some young pup will burst into the saloon and challenge the old dog to a duel he can't win.

filipw, to programming
@filipw@mathstodon.xyz avatar

if I asked you today to write an algorithm X that you need to compile as native library that can run in the browser, desktop Windows app and Android/iOS app, which language would you choose for that and why?

C is not allowed because it's year 2023 already and we can do better 😅

ginsterbusch, to php
@ginsterbusch@kosmos.social avatar

So, what in the name of the FSP is THIS?!?

$found_items = get_items_from_db();

$json = json_encode($found_items);
$x = json_decode($json);

Why would one even DO that?!?

veronica, to linux
@veronica@mastodon.online avatar

Windows may be an easy platform to use for simple things, but as a developer, there are no operating systems with as much friction as Windows. Linux is a breeze in comparison.

I have little experience with MacOS, and I find their UI very counter-intuitive and opinionated, but at the command line level it is easy enough to work with as well – for what I've had to deal with so far at least.

#Windows #Linux #Programming #DevOps

daz, to programming

How long do you keep renewing the domain name registration for the side project you never finished?

furbyonsteroids, to programming

So, testing the . I want it to rewrite a code snippet from using a switch statement to an if statement. Literally just to test it. And it's generating.. it's generating... It's generating. You can see the code being generated in front of your eyes in real time. Still generating.. almost done... Aaaand d--
Bing deletes everything and tells me it can't do that.

What do you mean? You literally just did it?!

ngaylinn, to programming

The best way I've found to design software is to get it totally wrong on the first try. Once you've seen why the obvious approach won't work, and how ugly your naive workaround is, you sleep on it and a better solution will present itself in the morning. Just make sure you do this in small chunks, or the epic rewrite will take you forever.

Actually, this is the only effective way I've found to design software. :blobcat_mlem:

aramloosman, to programming German

It took me a long time to try it for the first time, but I have the feeling that those «AI» Tools like ChatGPT will be a very often used Tool for programmers from now on. It is by no means perfect and you have to know what you are doing, but as Assistant it is very powerful!

preslavrachev, to programming
@preslavrachev@mastodon.social avatar
itsfoss, to programming
@itsfoss@mastodon.social avatar

Grab the Python programming bundle by No Starch Press.

Part of the proceeds go towards the Python Software Foundation!

⏱️ Ends on 22 May.
💸 $1 or more.

https://www.humblebundle.com/books/python-no-starch-books?partner=itsfoss

uliwitness, to gaming
@uliwitness@chaos.social avatar

TIL there is a series of little movies that teach game developers how to make game controls more accessible: https://specialeffectdevkit.info/

james, to programming

Either I've become a lot cooler or a lot more of a loser thanks to this new tattoo!

Sid even did it in my own handwriting which was an unexpected surprise! My third tattoo from him, love getting art from a fellow trans guy on my skin.

Siiiiiiiiiick.

jakub_neruda, to programming Czech
@jakub_neruda@techhub.social avatar

Every single day convinces me more and more that IDisposable interface is one of the most disastrous things in C#. So easy to screw up in so many ways...

  • All
  • Subscribed
  • Moderated
  • Favorites
  • megavids
  • thenastyranch
  • rosin
  • GTA5RPClips
  • osvaldo12
  • love
  • Youngstown
  • slotface
  • khanakhh
  • everett
  • kavyap
  • mdbf
  • DreamBathrooms
  • ngwrru68w68
  • provamag3
  • magazineikmin
  • InstantRegret
  • normalnudes
  • tacticalgear
  • cubers
  • ethstaker
  • modclub
  • cisconetworking
  • Durango
  • anitta
  • Leos
  • tester
  • JUstTest
  • All magazines