Better HN
topnewbestaskshowjobs
Log inSign up

shahriarhaque

72 karma · joined Jun 5, 2010 (16y ago) · 12 submissions

Submissions

1.

Challenges of pursing a CS degree at the CMU Qatar campus(shahriarhaque.com ↗)

1 points · by shahriarhaque · 14y ago · discuss

2.

Structural Pattern Matching using Exceptions(shahriarhaque.com ↗)

5 points · by shahriarhaque · 14y ago · discuss

3.

Pattern in the flags of Middle Eastern countries(shahriarhaque.com ↗)

1 points · by shahriarhaque · 15y ago · discuss

comment 15y ago · link · parent

I think this could be another brilliant addition to the "documentation view". Imagine a multi-tabbed documentation pane. The first tab lets you write normal comments, but in another one you could write doctests like the example you gave, or even assertion of pre and post conditions.

comment 15y ago · link · parent

When you start your source file with a huge chunk of "how" comments it is likely to not match the actual code path. But that's not how I think the "documentation mode" will work. You write how comments for every small chunk of code. Then whichever code path the program executes, you will see a flow of comments from that path

comment 15y ago · link · parent

I agree that "Why" comments are infrequent, but they are still important. I work in the scientific computing field and here "whys" are they key to understanding code. But lengthy explanations of why certain steps of the algorithm are needed, are very distracting. Such a scenario calls for a separation of code from comments.

7.

Don’t just write comments, tell a story(shahriarhaque.com ↗)

36 points · by shahriarhaque · 15y ago · 16 comments

comment 16y ago · link · parent

* Take out a spreadsheet, put down the names of your ideas in every row, put your evaluation criteria in the columns (Ease of development, New Skills, Current Progress, Real Life Value, etc). * Add a row at the bottom to specify the weights of your criteria. * Add a column to sum up the scores. * Sort Z-A by total score and pick the top 2/3.

9.

Swing Query & Annotated Event Listeners(squery.posterous.com ↗)

1 points · by shahriarhaque · 16y ago · discuss

comment 16y ago · link · parent

If you want to know learn how to implement not-so-out-of-the-box GUI elements, I will suggest a book called Swing Hacks. If you want advanced controls, plus some nice animations, try Filthy Rich Clients. Both books are for the Java Swing library.

11.

Why should JS coders have all the fun?(squery.posterous.com ↗)

31 points · by shahriarhaque · 16y ago · 9 comments

comment 16y ago · link · parent

I wouldn't say it's a Holy Grail or Magic Wand, or whatever you want to call it. I would say: learning a (pure) functional language, or taking a university course on it, is a religious experience. One that every programmer should go through to learn a new way of looking at problems.