Reputation: 9192 Deity
- Active Posts:
- 16,013 (8.93 per day)
- 19-March 11
- Profile Views:
- Last Active:
- 55 minutes ago
- Viewing Topic: What are you working on today?
- OS Preference:
- Favorite Browser:
- Favorite Processor:
- Who Cares
- Favorite Gaming Platform:
- Who Cares
- Your Car:
- Who Cares
- Dream Kudos:
- Expert In:
- Java, python, smartassery
Posts I've Made
Posted 14 Feb 2016
Posted 13 Feb 2016So, there was a piece of good news today: One of the most profoundly evil human beings to have walked this earth has finally shed his mortal frame and joined the choir invisible.
No, not Kissinger, I said human beings, I'm talking about Antonin Scalia. Dead at 79, and not a moment too soon. A great day for American jurisprudence.
(okay, Thomas, we're looking at you... can we go for a twofer?)
Posted 13 Feb 2016Can you give us an example? What is a concrete problem that you're having now, or have had recently?
Posted 13 Feb 2016I've moved this to the Software Development forum, which seems the most appropriate.
QuoteWhat should I do to understand algorithms easier and to improve my "algorithmic way of think"? Where should I begin studying?
I get the feeling that there's a specific question lurking under this general one. What's the particular problem that's causing you trouble right now? It might be easier to address that. "Understanding" an existing algorithm, "creating" a new one for a new situation, and "implementing" some algorithm (which you may have created and/or understood), are three different things, so it would be nice to reduce the scope of the question a little bit.
That being said, the usual first step is to learn by example, by taking well-known algorithms and examining the ways they work and how we analyze them, and finally implementing them in some particular language. The goal is to be able to think about algorithms as abstract procedures, so the implementation is mostly useful as a tool for understanding the details of the algorithm. The particular benefit here is to focus your mind on the important things: can we prove that this algorithm is effective, and can we understand its time complexity?
After you have a good understanding a number of existing algorithms and you've performed this sort of analysis often enough, it'll be easier to think about creating algorithms.
Posted 12 Feb 2016The shuffle function looks better. I will assume that if it passes all of the tests that you can throw at it, that it's probably pretty good.
At this point, I would hand it off to you: when you look at this, what do you think? Is there anything about it that you're not happy with? Does it seem to you like you could come back to it six months from now and understand what it was doing and how it was doing it? If you wanted to change something about it, how hard would that be? For example, what if the deck were changed to include another suit? What if the target were changed to some other value? What if you wanted to implement the standard casino practice of using multiple decks?
You will find that these sorts of questions are important for a programmer, and it's useful to start thinking about them now. Flexibility and adaptability are greatly to be prized, and the ability to see where your code constrains you before you run into that constraint is a good one to develop.
- Member Title:
- Age Unknown
- Birthday Unknown
- Boston, MA
- Translation (Portuguese, German, Spanish), accordion (Hohner Black Dot B/C), flute (Casey Burns, Skip Healy 3-piece), homebrew (beers and meads)
- Full Name:
- Jon Kiparsky
- Programming Languages:
- Java, python, scala, perl, c, various lispen, bits and pieces of this and that