Lucian Ghindaallaboutcoding.ghinda.com·Dec 6, 2024How to Return Multiple Values from a Method in Ruby Using Data.defineI read a question on Bluesky and X that I quickly replied to, but I wanted to expand on my recommendation. The context This is the code that was originally shared and we were asked for our opinion on it. def something_with_two_outputs a = parse_dat...1 like·294 readsRuby
ritiksharmaaaritiksharmaaa.hashnode.dev·Nov 26, 2024Design Principles in Software DevelopmentDesign principles aim to provide solutions to recurring problems in software architecture. Below is a detailed article explaining common design patterns using real-world analogies, the problem they solve, and their implementation in both Python and J...Data Structure And Algorithmspatterns
Stephane Bersierbersier.hashnode.dev·Oct 21, 2024Proposed type reduction rule for Scala 3Below is a copy of a draft outlining the proposal of an additional rule for match type reduction in Scala 3. It was shared (as a Mathcha link) on Scala Contributors, as a follow-up to this discussion. In this draft is presented an additional subtypin...Scala
Asfaq Leeonleeonscoding.hashnode.dev·Aug 12, 2024A simple regular expression exampleOnce upon a time, simple regex patterns are really hard to understand to me. But now-a-days, I can write simple regex patterns comfortably. Few weeks ago, I also have written a complex one. Today I'm going to share how I approach a regex problem. Tod...Regex
Edward Obohedwardoboh.hashnode.dev·Jun 29, 2024Comparing fnmatch and regexPattern matching is a fundamental aspect of text processing, enabling powerful searches and manipulations in various applications. Two common methods for pattern matching are fnmatch and regex. Each has its strengths and limitations, and understandin...fnmatch
Alex Mboutchouangblog.alexwalker.tech·May 27, 2024Python structural pattern matchingIn the list of new features when version 3.10 of Python was announced, structural pattern matching was one of the most innovative features for me. While most people describe that as the Switch...case Pattern that we know in other popular programming ...Python
Sushant Pantsushantpant.com.np·Mar 22, 2024Pattern Matching, Switch Expression and MoreOne of the major feature of C# version 7.0 was pattern matching. Pattern matching is a way to recognize structure or pattern within some context. Think of pattern matching like a simple puzzle where you examine the pieces and look for matching edges ...10 likes·179 readspattern-matching
Jindřich Ivánekjindraivanek.hashnode.dev·Jan 18, 2024F# tips weekly #2: Single case pattern matchEvery F# programmer is likely familiar with pattern matching using the match keyword, as illustrated below: match x with | Some 0 -> "Zero" | Some n when n > 0 -> "Positive" | Some n when n < 0 -> "Negative" | None -> "Unknown" However, a less well-...4 likes·591 readsF# tips weekly#fsharp
Slawomir Moriakslamcode.hashnode.dev·Jan 2, 2024Resources to types with 'infer'Learn how you can make any string-based resource into a TypeScript type, and make the compiler do the hard work of checking the data for you. The magic of pattern matching in conditional types with the help of infer keyword is the topic for today. Ca...37 readsTypescript magicTypeScript
Oluwatobi Oluyedeyuzr.hashnode.dev·Dec 17, 2023Pattern Matching with JavaScript Regular Expressions: An IntroductionIn the intricate world of web development, the mastery of Regular Expressions opens the door to a world of powerful pattern matching. From validating user input to searching and manipulating strings, regular expressions serve as the linchpin for craf...JavaScript Regular ExpressionsJavaScript