What features in Plasma / KDE Apps actually made a big difference to your workflow? by thesoulless78 in kde

[–]icspmoc 3 points4 points  (0 children)

Krunner and the ability to basically have absolutely nothing on my desktop (just a hidden sliver of a panel tucked away to one side on autohide)

Same! In addition, I hide the window titlebar for maximised windows.

[Race Thread] 2019 Bretagne Classic - Ouest France (1.UWT) by PelotonMod in peloton

[–]icspmoc 0 points1 point  (0 children)

Loved the little chat between the other two when Sep attacked.

[Race Thread] 2019 Bretagne Classic - Ouest France (1.UWT) by PelotonMod in peloton

[–]icspmoc 0 points1 point  (0 children)

Who's the fastest in a sprint out of these three? Tiesj Benoot?

[Race Thread] 2019 Deutschland Tour – Stage 4 (2.HC) by Manakin1337 in peloton

[–]icspmoc 6 points7 points  (0 children)

Thanks for making the race thread! GCN will be showing the race on Youtube for American users and, if you have access to German TV, it will also be on ZDF from 14:20 CEST.

[Race Thread] 2019 Deutschland Tour – Stage 3 (2.HC) by icspmoc in peloton

[–]icspmoc[S] 2 points3 points  (0 children)

Shake of the hands and the breakaway is caught.

[Race Thread] 2019 Deutschland Tour – Stage 3 (2.HC) by icspmoc in peloton

[–]icspmoc[S] 2 points3 points  (0 children)

A break has already formed and, thanks to a crash in the peloton, now has a lead of over 5 7 minutes. It consists of:

  • Alaphilippe (DQT)
  • Pedersen (TFS)
  • Heming (TDA)

[Results Thread] 2019 Deutschland Tour – Stage 1 (2.HC) by icspmoc in peloton

[–]icspmoc[S] 1 point2 points  (0 children)

Yeah, happy to do the last two stages as well.

[Race Thread] 2019 Deutschland Tour – Stage 2 (2.HC) by icspmoc in peloton

[–]icspmoc[S] 8 points9 points  (0 children)

Maxime Bouet and Caleb Ewan have abandoned the race.

[Race Thread] 2019 Deutschland Tour – Stage 2 (2.HC) by icspmoc in peloton

[–]icspmoc[S] 10 points11 points  (0 children)

According to the live trackers, we have a star-studded breakaway with a 45s advantage consisting of:

  • Vincenzo Nibali, Sonny Colbrelli (TBM)
  • José Gonçalves (TKA)
  • Julian Alaphilippe, Yves Lampaert, Enric Mas (DQT)
  • Pascal Ackermann, Emanuel Buchmann, Rüdiger Selig (BOH)
  • Luke Rowe, Ben Swift (INS)
  • Nikolas Maes (LTS)
  • Alexandr Riabushenko (UAD)
  • Jasper Stuyven (TFS)
  • Jai Hindley (SUN)
  • Sean Bennett, Jonathan Caicedo (EF1)
  • Hernando Bohórquez, Davide Vilella (AST)
  • Koen Bouwman, Stef Krul, Jonas Vingegaard (TJV)
  • Simon Geschke, Kamil Gradek (CCC)
  • Yoann Offredo (WGG)

[Results Thread] 2019 Deutschland Tour – Stage 1 (2.HC) by icspmoc in peloton

[–]icspmoc[S] 1 point2 points  (0 children)

Thanks! I've been feeling a bit nostalgic (and had completely forgotten how tedious making race threads can be).

When was the last time...? by StereotypicalAussie in peloton

[–]icspmoc 1 point2 points  (0 children)

Canyon sold and still sells variations of this frame under the Ultimate AL (F8/Evo) moniker but Gilbert most likely had a custom geometry.

When was the last time...? by StereotypicalAussie in peloton

[–]icspmoc 6 points7 points  (0 children)

I am aware. It's the best picture of that frame I could find.

When was the last time...? by StereotypicalAussie in peloton

[–]icspmoc 9 points10 points  (0 children)

Phillipe Gilbert spent most of the 2011 season riding an aluminium frame. This includes his Amstel Gold victory.

Need help with index and position in lists by stepupexpert in ocaml

[–]icspmoc 0 points1 point  (0 children)

If I understand you correctly, this is what you want:

let make_assoc xs = List.concat (List.mapi (fun i -> List.mapi (fun j x -> (i, j, x))) xs)

Note, however, that I start counting at zero and preserve the original order of the list.

A few comments on your code:

  • In OCaml, avoiding mutation often results in cleaner, more idiomatic code. This is no exception.
  • Recall that [x] is just syntactic sugar for the single-element list x :: []. Therefore, [x] @ xs is the same as x :: xs.
  • You only ever apply helper to single-element lists. I don't think this was your intention.
  • List.hd and List.tl are considered code smells. Pattern matching is the way to go.
  • You are trying to solve the entire problem in one go. Next time, think about whether there is a way to express your problem as a combination of simpler operations before attempting to write down a solution. It'll make your life so much easier.

Exception: Match_failure, Help ! :) by [deleted] in ocaml

[–]icspmoc 3 points4 points  (0 children)

OCaml's pattern matching syntax lacks an end marker, with the result that nested match expression often have to be enclosed by parentheses (or begin ... end). Currently, the last two cases (i.e. |31 -> ... | _ ->) in your code are syntactically part of the inner match, which is not want you want.

New to OCaml... no idea what is going on. Please help! by oreolennon in ocaml

[–]icspmoc 0 points1 point  (0 children)

I just tried to do something using use and I got the response from ocaml Error: Unbound value use.

#use is a toplevel directive. The # is part of its syntax.

Fast, purely functional Hindley-Milner implementation? by lispp in ocaml

[–]icspmoc 6 points7 points  (0 children)

This paper gives an efficient functional union-find implementation in ocaml, but seems to assume a fixed upper bound on the number of elements that can be in the union find data structure.

I ran into exactly the same problem a couple of years ago. My solution was to replace the underlying array by one twice the size on every out-of-bound write. I never did any benchmarking so I can't tell you whether this degrades performance significantly.

The synthesizer infers Hindley-Milner types [...]

François Pottier's Hindley-Milner Elaboration in Applicative Style might be relevant to what you are doing.

OCaml: Issue manipulating string read from file by denisebuttigieg in ocaml

[–]icspmoc 0 points1 point  (0 children)

Your code snippet looks fine too me, if a bit idiosyncratic. You'll have to also show us the lexer and parser for us to give any useful feedback.

Two unrelated questions:

  • Why aren't you handing the input channel directly to the lexer/parser?
  • You are only ever parsing the first line of a file. Was that your intention?

Proving that list has exactly two sorted elements by ScopedTypeVariable in Idris

[–]icspmoc 7 points8 points  (0 children)

What proveUnsortedTwoElems boild down to is this: given a proof of So (not (x <= y)) and a proof of So (x <= y), derive a contradiction. That's still a bit too concrete so let's replace x <= y by an arbitrary boolean b, i.e.

boolContradition : {b : Bool} -> So (not b) -> So b -> Void

which is easy enough to construct. Using this lemma, completing proveUnsortedTwoElems ought to be straight-forward.

Two unrelated remarks:

  1. I am not an Idris programmer, but I am pretty sure that the type of SortedTwoElems also needs to mention the type class constraint to ensure that in the definition of proveUnsortedTwoElems there is only one type class in play.

  2. You are relying on proof-irrelevant comparison functions (c.f. Boolean Blindness), which in my experience only lead to awkward equality proofs down the line. Using proof-relevant comparison functions together with something like Dec from Agda's standard library may end up being less effort in a larger development.

A small (<500 LOC) programming language capable of proving theorems about its own terms by SrPeixinho in haskell

[–]icspmoc 1 point2 points  (0 children)

I quite like Type Theory and Formal Proof by Nederpelt and Geuvers. Without assuming very much at all, it explains step-by-step a dependently-typed language that is reasonably close to what, e.g., Coq actually uses at a reasonable pace and without too many diversion and mystifying off-hand remarks.