There have been multiple accounts created with the sole purpose of posting advertisement posts or replies containing unsolicited advertising.

Accounts which solely post advertisements, or persistently post them may be terminated.

lennivelkant ,

I’ve never worked with Haskell, but I’ve been meaning to expand my programming repertoire (particularly since I don’t get to do much coding at work, let alone learn new languages) and this makes for a nice opportunity, so I wanna try to parse this / guess at the syntax.

I assume iterate function arg applies some function to arg repeatedly, presumably until some exit condition is met? Or does it simply create an infinite, lazily evaluated sequence?

( ) would be an inline function definition then, in this case returning the result of applying ++suffix to its argument (which other languages might phrase something like arg += suffix), thereby appending " Is Not an Emulator" to the function argument, which is initially “WINE”.

So as a result, the code would produce an infinite recurring “WINE Is Not an Emulator Is Not an Emulator…” string. If evaluated eagerly, it would result in an OOM error (with tail recursion) or a stack overflow (without). If evaluated lazily, it would produce a lazy string, evaluated only as far as it is queried (by some equivalent of a head function reading the first X characters from it).

How far off am I? What pieces am I missing?

  • All
  • Subscribed
  • Moderated
  • Favorites
  • [email protected]
  • random
  • lifeLocal
  • goranko
  • All magazines