সোমবার, ২ জানুয়ারী, ২০১৭

Advice from an old programmer

Advice from an Old Programmer

You've finished this book and have decided to continue with programming. Maybe it will be a career for you, or maybe it will be a hobby. You'll need some advice to make sure you continue on the right path and get the most enjoyment out of your newly chosen activity.
I've been programming for a very long time. So long that it's incredibly boring to me. At the time that I wrote this book, I knew about 20 programming languages and could learn new ones in about a day to a week depending on how weird they were. Eventually though this just became boring and couldn't hold my interest anymore. This doesn't mean I think programming is boring, or that you will think it's boring, only that I find it uninteresting at this point in my journey.
What I discovered after this journey of learning is that it's not the languages that matter but what you do with them. Actually, I always knew that, but I'd get distracted by the languages and forget it periodically. Now I never forget it, and neither should you.
Which programming language you learn and use doesn't matter. Do not get sucked into the religion surrounding programming languages as that will only blind you to their true purpose of being your tool for doing interesting things.
Programming as an intellectual activity is the only art form that allows you to create interactive art. You can create projects that other people can play with, and you can talk to them indirectly. No other art form is quite this interactive. Movies flow to the audience in one direction. Paintings do not move. Code goes both ways.
Programming as a profession is only moderately interesting. It can be a good job, but you could make about the same money and be happier running a fast food joint. You're much better off using code as your secret weapon in another profession.
People who can code in the world of technology companies are a dime a dozen and get no respect. People who can code in biology, medicine, government, sociology, physics, history, and mathematics are respected and can do amazing things to advance those disciplines.
Of course, all of this advice is pointless. If you liked learning to write software with this book, you should try to use it to improve your life any way you can. Go out and explore this weird, wonderful, new intellectual pursuit that barely anyone in the last 50 years has been able to explore. Might as well enjoy it while you can.
Finally, I'll say that learning to create software changes you and makes you different. Not better or worse, just different. You may find that people treat you harshly because you can create software, maybe using words like "nerd." Maybe you'll find that because you can dissect their logic that they hate arguing with you. You may even find that simply knowing how a computer works makes you annoying and weird to them.
To this I have just one piece of advice: they can go to hell. The world needs more weird people who know how things work and who love to figure it all out. When they treat you like this, just remember that this is your journey, not theirs. Being different is not a crime, and people who tell you it is are just jealous that you've picked up a skill they never in their wildest dreams could acquire.
You can code. They cannot. That is pretty damn cool.








 [Total credit is of www.learncodethehardway.org]

বৃহস্পতিবার, ২৯ ডিসেম্বর, ২০১৬

Python nosetests assert functions

Python Nose setup assert functions:
 
nose.tools.assert_equal
nose.tools.assert_equals
nose.tools.assert_not_equal
nose.tools.assert_not_equals
nose.tools.assert_almost_equal
nose.tools.assert_almost_equals
nose.tools.assert_not_almost_equal
nose.tools.assert_not_almost_equals
nose.tools.assert_items_equal 
nose.tools.assert_tuple_equal 
nose.tools.assert_dict_equal
nose.tools.assert_dict_contains_subset 
nose.tools.assert_list_equal 
nose.tools.assert_tuple_equal
nose.tools.assert_set_equal
nose.tools.assert_sequence_equal
nose.tools.assert_raises
nose.tools.assert_raises_regexp
nose.tools.assert_regexp_matches 
nose.tools.assert_not_reg 
nose.tools.assert_raises
nose.tools.assert_multi_line_equal 
nose.tools.assert_less 
nose.tools.assert_less_equal
nose.tools.assert_greater
nose.tools.assert_greater_equal
nose.tools.assert_true
nose.tools.assert_false 
nose.tools.assert_in
nose.tools.assert_not_in
nose.tools.assert_is
nose.tools.assert_is_instance 
nose.tools.assert_is_not
nose.tools.assert_is_not_none