Recent content by [)roi(]

  1. [)roi(]

    Functional Thread 11 : Traversable Functors

    Traverse IEnumerable implementation with other data types public static Maybe<IEnumerable<B>> Traverse<A, B>(this IEnumerable<A> @this, Func<A, Maybe<B>> f) => @this.Fold(Just(Enumerable.Empty<B>()), (a, e) => Just(Append<B>().Curry()).Apply(a).Apply(f(e))); public static...
  2. [)roi(]

    Functional Thread 11 : Traversable Functors

    Traversable Functors We already have studied four of the five algebras that are typically used for data structure manipulation: Monoid -- Fold -- Linq's Aggregate Functor -- Map -- Linq's Select Applicative Functor -- Apply -- Linq's does not include this. Monad -- FlatMap -- Linq's SelectMany...
  3. [)roi(]

    Functional Thread 11 : Traversable Functors

    Represents a class of data structures that conform with the Traversable Functor algebra which is a structure that can be traversed from left to right, performing an action on each element. Reference: Applicative Programming with Effects The two main methods are: traverse :: Applicative f =>...
  4. [)roi(]

    Team Blind

    Close on 2 decades ago a few friends of mine & me decided to leave our corporate comfort seats and go solo; starting up a business that focused on providing an advanced level of skills to bolster and/or fast track projects.
  5. [)roi(]

    Team Blind

    Roles also not a close match; used Full Stack Developer. San Francisco: 50th $258K 75th $325K London: 50th £102K 75th £129K Sydney: 50th $187K 75th $236 Proof at least in my case that working for a corporate is no longer a financially sound decision. // edit Language options appear to have a...
  6. [)roi(]

    Functional Thread 9 - Tagged Union Types

    The code for the latest iteration of the pattern matching has been uploaded to github included some bug fixes on the tagged type related to the functor, monad and applicative functor algebras. I have also added a first draft implementation of the Continuation Monad aka "mother of all monads"...
  7. [)roi(]

    Functional Thread 9 - Tagged Union Types

    Update to the Tagged Union Type I've recently wrapped up a simplification of the switch / case for the Tagged Union Types I discussed previously. Pattern matching over these types previously required a tuple, with the following type signature: params (Func<E, bool> predicate, Action<Tagged<E...
  8. [)roi(]

    Functional Programming

    Here's a link to my PHPrelude functional programming repo, which is built off a base of the PHP Vector basic functional combinator framework. There is however no dependency to Vector -- all the Vector code that I use has been builtin and modified to tie in better with my monadic data type...
  9. [)roi(]

    Web development and problem solving

    There are no bad programming languages, only bad programmers. http://wiki.c2.com/?BadProgrammer
  10. [)roi(]

    Functional Programming

    Sure, I'll find time this weekend to put up a copy on github; will PM you once it's done. As for you struggling with where to use it; that's normal for everyone in the beginning & all part of the learning. The monad can replace almost every parcel of code, because it's an abstraction of very...
  11. [)roi(]

    Functional Programming

    I built my own PHP FP library a while back; covering many of the base data types (e.g. Identity, Maybe, Either, Reader, Validation) including many combinators. You're welcome to a copy of the code if you like?
  12. [)roi(]

    Functional Thread 10 : Monadic Composition

    Example of a Monad's ability to manipulate state? To illustrate manipulation of state; lets look at the implementation for a monadic filter function. public static Func<A, IEnumerable<A>> Filter<A>(Predicate<A> p) => a => p(a) ? Enumerable.Empty<A>().Append(a) : Enumerable.Empty<A>(); var...
  13. [)roi(]

    Functional Thread 10 : Monadic Composition

    Abstract behaviour of a Monad Picking up from the previous post on Monads; let's try to make some sense of the abstract behaviour of the Monad in order to understand why it's a perfect algebra to safely model an imperative computation. In order to understand why it's function signature is...
  14. [)roi(]

    Functional Thread 10 : Monadic Composition

    My pleasure; happy to hear it's helpful. Here's another bonus: I've recently made the decision to open source a new repository incorporating most of the functional API I use in production; shared as a set of Nugets and a github repository. Practical caveat is that only the latest C# language...
Top