technige, to programming
@technige@fosstodon.org avatar

languages can be split into three categories: static (e.g. Java, C#), dynamic (e.g. Python, Ruby), and cosplay static (e.g. TypeScript, Python-with-typing).

stevensanderson, to programming
@stevensanderson@mstdn.social avatar

🔎 Selecting Columns Containing a Specific String in R: A Quick Guide 🚀

Hey R users! Need to select columns by a specific string? Here's how in base R, stringr, stringi, dplyr, and with a bonus from data.table.

🆒 R
✅ grepl
📦 stringr
📦 stringi
📦 dplyr

Bonus: 📦 data.table
library(data.table)
df_price <- df[, names(df) %like% "price"]

Happy coding! 🚀

Post: https://www.spsanderson.com/steveondata/posts/2024-05-15/

#R

image/png
image/png
image/png

libreoffice, to programming
@libreoffice@fosstodon.org avatar

Something for coders! New post on the development blog – fixing assertion failures: https://dev.blog.documentfoundation.org/2024/05/14/crash-fixes-part-4-assertion-failure/

albertcardona, to Java
@albertcardona@mathstodon.xyz avatar

In java, is there a simple, idiomatic, standard-library built-in way to iterate a Stream n elements at a time? E.g., in pairs, using a BiConsumer or similar two-argument Function?

jjimenezshaw, to programming
@jjimenezshaw@mapstodon.space avatar

"If the authors of computer programming books wrote arithmetic textbooks..."

A colleague used this image to describe the documentation of a library. Meaning that the documentation was the example with the rabbits, but they have to use the library as the second part of the image.

davep, to python
@davep@fosstodon.org avatar

I’ve just released v0.14.0 of Tinboard, my client for the . This release adds the start of an application settings dialog, with the first couple of options letting you set the default value for the "private" and “read-later" state of new bookmarks.

https://blog.davep.org/2024/05/14/tinboard-0-14-0.html

ArneBab, (edited ) to random German
@ArneBab@rollenspiel.social avatar

define-typed: a static type syntax-rules macro for to create API contracts and help the JIT compiler create more optimized code:

https://www.draketo.de/software/guile-snippets#define-typed

Improved thanks to feedback from Vivien and Zelphir in the Guile User mailing list.

Just 26 lines to get argument and return value typing without changing Guile.

I love the flexibility of ❤️

argv_minus_one, to rust
@argv_minus_one@mstdn.party avatar

I wonder if anyone has ever written an embedded in which there is no run-time interpreter, and all SQL queries are translated into machine code at compile time.

Kinda like sqlx, except queries are fully compiled at compile time, not just checked for correct syntax and types.

I'm guessing this would be extremely specific to one language, and outright impossible in most programming languages.

hankg, to vmware

Cue the "It's a trap!" meme, especially in light of recent developments post-Broadcom acquisition..."VMware giving away Workstation Pro, Fusion Pro free for personal use"
VMware giving away Workstation Pro, Fusion Pro free for personal use

Jorvon_Moss, to ArtificialIntelligence
@Jorvon_Moss@mstdn.social avatar

My face when my codeing. its not my fav part

swiftcraft, to programming
@swiftcraft@hachyderm.io avatar

🌟Exclusive offer for job seekers!🎉

Dive into the world of Swift development at SwiftCraft's main conference for just £90 + workshops or tutorials for an additional £90 each!

Find out more and apply! https://swiftcraft.uk/jobseekers

lefebvre, to programming
@lefebvre@hachyderm.io avatar

Save 20% on Xojo, a bargain at any price! Also, SQLVue (my SQLite database editor) is only $12 during this sale!

https://www.xojo.com/store/

(Click on Extras tab for SQLVue.)

stevensanderson, to programming
@stevensanderson@mstdn.social avatar

Want to check duplicate values across columns of a data.frame? Well you can do that in a basic way with TidyDensity and the check_duplicate_rows() function, or you can go through todays blog post for some other ideas with and

#R

Post: https://www.spsanderson.com/steveondata/posts/2024-05-14/

image/png

devstory, to php Czech
@devstory@mastodonczech.cz avatar

phpFashion.com ( @davidgrudl ) - How to Handle Getters When They Have Nothing to Return?

https://phpfashion.com/en/how-to-handle-getters-when-they-have-nothing-to-return

nette_news, to php
@nette_news@phpc.social avatar

📝 Group and Sort Data in Latte Templates Like a Pro

In the latest update of Latte, we are introducing several significant enhancements that will simplify and make more efficient the work with data in your templates.

https://blog.nette.org/en/group-and-sort-data-in-latte-like-a-pro

dirkdierickx, to programming
@dirkdierickx@mastodon-belgium.be avatar

1984 - Ashton-Tate introduces the dBase III relational program for IBM PC-compatible computers.

dBase was one of the first database management systems for microcomputers and the most successful in its day. The dBase system included the core database engine, a query system, a forms engine, and a language that tied all of these components together.

frankel, to programming
@frankel@mastodon.top avatar

Rosetta Code, a chrestomathy site

https://rosettacode.org/wiki/Rosetta_Code

zeroiee, to programming
@zeroiee@techhub.social avatar

A clean Git history is the key to successful teamwork and quick bug fixes. Errors can only be successfully tracked down if it is always possible to trace when and where code was changed by whom and for what reason.

🥴 However, in the rush of the battle, the changes that are packaged in a commit are sometimes not taken very seriously. Who has never experienced this? A change that is actually unrelated to the current work package has made it into the commit because the file has already been saved temporarily.

💡The solution: With an "interactive add" (git add -i), you can pack partial changes ("hunks") into a commit and specify line by line what should be included in the next commit.

:git: "Staging patches": https://git-scm.com/book/en/v2/Git-Tools-Interactive-Staging

henrikjernevad, to programming
@henrikjernevad@mastodon.social avatar

Should you build software that is extensible and future-proof?

That sounds like a good idea, doesn’t it? Well, that depends on how good you are at predicting the future.

https://henko.net/blog/design-for-today/

leanpub, to books
@leanpub@mastodon.social avatar
pablolarah, to programming
@pablolarah@mastodon.social avatar

🟠 Avoiding the soft delete anti-pattern
by Tim Fisken @culturedsystems

https://www.cultured.systems/2024/04/24/Soft-delete/

julienbarnoin, to cpp
@julienbarnoin@mastodon.gamedev.place avatar

All this time I've been using the return value of snprintf as the number of characters actually written, when it's in fact the number of characters that would be written if the max size passed in were large enough.

In fact: "If the resulting string would be longer than n-1 characters, the remaining characters are discarded and not stored, but counted for the value returned by the function."

BRB, got a bunch of files to go back over... 😓

#c

lily, to rust
@lily@glaceon.social avatar

the rust "impl" keywork is kinda weird.

usually, it is used to define methods, but in function arguments, it serves as syntactic sugar so you don't have to name generic types... but in a return type, it has a meaning that is slightly different, and actually expresses a semantic not even vanilla haskell can represent!

basically, instead of being able to return any type implementing a trait, it states that it can return at least one type that implements a trait.

in haskell terminology, specifying a generic type parameter is "forall a", while returning an "impl" is "exists a".

#rust #rustlang #haskell #programming #typesystems

Crell, to python
@Crell@phpc.social avatar

Teaching folks the joys of clear and explicit object type definitions. An interesting experience...

saturn85, to programming
@saturn85@mastodon.world avatar
  • All
  • Subscribed
  • Moderated
  • Favorites
  • JUstTest
  • modclub
  • DreamBathrooms
  • InstantRegret
  • tacticalgear
  • magazineikmin
  • Youngstown
  • thenastyranch
  • mdbf
  • slotface
  • rosin
  • Leos
  • kavyap
  • Durango
  • normalnudes
  • ethstaker
  • everett
  • GTA5RPClips
  • cubers
  • khanakhh
  • ngwrru68w68
  • anitta
  • provamag3
  • cisconetworking
  • tester
  • osvaldo12
  • megavids
  • lostlight
  • All magazines