TE
テックエコー
ホーム24時間トップ最新ベスト質問ショー求人
GitHubTwitter
ホーム

テックエコー

Next.jsで構築されたテクノロジーニュースプラットフォームで、グローバルなテクノロジーニュースとディスカッションを提供します。

GitHubTwitter

ホーム

ホーム最新ベスト質問ショー求人

リソース

HackerNews APIオリジナルHackerNewsNext.js

© 2025 テックエコー. すべての権利を保有。

Silly job interview questions in Haskell

85 ポイント投稿者: behnamoh2日前

8 comments

sshine2日前
I live-coded Haskell a couple of times at job interviews for non-Haskell positions where you were free to choose.<p>It’s fun because the interviewer often doesn’t grok the paradigm. In one case, I was asked to make a password generator, and I went with QuickCheck’s Gen, which lets me write a random generator of things without explicitly defining a single function (they’re all monads).<p>So you go from somehow describing the thing you want to make to “I’m done.” :-D
评论 #44070497 未加载
djtango2日前
I remember I did an Advent of Code day 1 in Haskell a while back.<p>The meat of the code was a one liner. But opening a file, throwing away the first line and parsing a CSV took a lot more head scratching, especially if you&#x27;ve only ever done puzzles in Haskell.<p><i>Makes the hard things easy and the easy things hard</i>
评论 #44070361 未加载
评论 #44074400 未加载
pentaphobe2日前
Always fun to see this kind of Rosetta Code thing, feel like no matter the topic there&#x27;s something to glean from reading!<p>That said: if I ever gave the palindrome question to a candidate (I haven&#x27;t) and they pulled out a `reverse` library func&#x2F;keyword we&#x27;d be encouraging them to do more.
评论 #44072547 未加载
thdhhghgbhy2日前
Typical Haskell coding post with no mention of order or efficiency of the algorithm solutions. The thing is, even in basic coding quizes, if the interviewer is worth their salt, they will ask about how to improve the efficiency of the naive solutions first put forward, like the palindrome answer in this post.<p>What is the order of sumNToTotal?
评论 #44070794 未加载
评论 #44070915 未加载
评论 #44070762 未加载
评论 #44070880 未加载
评论 #44070932 未加载
评论 #44072812 未加载
lynx972日前
Well, that fizlle implementation is not a good example of a great answer. It checks for the two conditions twice. At least I would use a where clause to define fizz and buzz.
评论 #44071328 未加载
ReDress2日前
&gt; Silly job interview questions in Haskell.<p>Well, it&#x27;s not clear to me why we&#x27;re terming these as silly. They mostly seem simple, instead, to me.
Sourabhsss12日前
Words for the functions are easy to understand.
pensatoio2日前
Fifteen years into my career, and I&#x27;m finally realizing that &quot;expressive&quot; languages are practically unreadable.
评论 #44069680 未加载
评论 #44069706 未加载
评论 #44069809 未加载
评论 #44069990 未加载