Category: Technology

Getting started with Ruby – Part 6

After having covered most of the basics of Ruby, lets get started on an actual problem, just like I had promised in my previous article – Getting started with Ruby – Part 5

I am taking a relatively simple problem that came in Google Codejam 2009 qualification round. Here is the direct link to the problem – Alient Language
Read More →

Getting started with Ruby – Part 5

Hi in my previous article Getting started with Ruby – Part 4 I covered Hashes & blocks. Today I will take you through the various forms of loops in Ruby.
Read More →

Getting started with Ruby – Part 4 – Hashes & Blocks

In my previous article Getting started with Ruby – Part 3 I started with Collections and covered basics of Ranges & Arrays. Like I mentioned towards the end of the article (in case you couldn’t manage to reach the end) I will start with one of the most commonly used Collection objects in Ruby, namely Hashes.
Read More →

Getting started with Ruby – Part 3 – Collections, Ranges & Arrays

In my previous article Getting started with Ruby – Part 2 I introduced you all to Ruby & its philosophy and I started out with data type classes in Ruby. I was able to give you an overview about Strings & Numbers in ruby. Today I will start with Collections.
Read More →

Getting started with Ruby – Part 2 – Introduction & Philosophy

Hi again, this is part 2 of my series of articles to help beginners getting started with the Ruby programming language. At this point of time I would like to quote the definition of Ruby from the Ruby-Lang official website.

A dynamic, open source programming language with a focus on simplicity and productivity. It has an elegant syntax that is natural to read and easy to write.

I know I had already quoted Ruby’s definition from wikipedia in my previous article ‘Getting started with Ruby – Part 1‘, but that was more of a technical definition. Here I wanted to draw your attention to Yukihiro Matsumoto‘s, popularly known as Matz’s philosophy behind creating Ruby, which is making programming as simple & natural as humanely possible. We will be witnessing that very soon.
Read More →

Getting started with Ruby – Part 1

Before we get started with Ruby, let me first give you a brief on who I am, I am Dhruva Sagar, a software engineer having a little over 4 years of professional experience having worked in technologies in and around Java, Javascript, Adobe Flex, PHP and Ruby. I have always been fascinated by programming languages and have been eager to learn new ones and I can also code comfortably in Perl, Python & Groovy, however I haven’t worked extensively on these. Right now I am working in a startup Artha42 Innovations Private Limited and am having the best time of my life!
Read More →

Moving to Ubuntu

I have worked on quite a few Linux distros, Redhat, Knoppix, BackTrack, PHLAK, ubuntu, etc. But most of the times I did that only to explore the realm of Linux and see for myself what the wonder is all about and explore a little more for the particular distro’s utilities, and not to actually shift myself completely to using it solely, since I have been accustomed to using windows and the various softwares that I use on windows for doing various tasks.

In the last few years I have had a huge inclination towards open source applications simply because they are good! I have found most open source applications to be really very good, highly usable, highly useful and really a source of inspiration for a fellow developer like myself and several others out there. The fact that you create a software for your benefit and release as open source and then other great developers from across the world who may share your interests in the tool can actually contribute to your application and help it become better is simply superb. This is what makes open source applications even better than commercial applications in the long run (most of the times). Also open source applications have a much better chance of enhancing and adding functionality that users wish for compared to commercial applications and this also makes them better over the long run.

The more I have been shifting to using alternate open source applications, the more I have been inclined towards moving to using a linux distro on my system as I no longer am restricted to the windows environment which is rather rigid and inflexible for my liking to say the least, and as a developer I also have a better environment under linux for using, appreciating, and even enhancing or contributing to open source applications!

I bought my laptop about a year back and it came with pre-installed Windows Vista (licensed version). Although I was rather frustrated by the various issues of the operating system, but the fact that several of the softwares I used previously were (at the time) not compatible either fully or partially to Vista added to my frustration. During this frustrating period I also found open source applications to be rather quicker to becoming compatible to Vista’s environment compared to several commercial applications that I used, which increased my appreciation for them.

My laptop has 1GB RAM and I really believe that it is not that low, but Windows Vista completely undermines my belief at most times. I have often found that Vista itself hogs about 60% of my memory and to my surprise that is huge! Perhaps it could be due to the various applications I have installed on my system and the various settings pertaining to the visual aspects of the operating system that were perhaps making Vista hog a little more of my memory that it would under normal conditions, but still in my opinion this sucked!

But for a long period of time I still continued using Windows Vista for the simple reason that I had already built quite a huge data repository (books, softwares, videos, music) which I normally keep on my system and now separating a 10GB or so partition for a linux would be a little cumbersome. Slowly and steadily most of the applications I used became Vista compatible and that added to my comfort to just continue using Vista as it is and just patiently put up with whatever memory hassles I have and I also thought if it gets a little out of hand, I could perhaps even even go for a memory upgrade and that would make things better. To be honest, it was simply easier to let Vista control the system rather than me having to go out of the way to control the system, at least under the circumstances.

For many who would know, I joined SAP Labs India about a month back and so far my time here has been quite interesting, I am part of a nice and enthusiastic team and there is quite a lot that I am and will learn here, if things go well. Here my colleagues introduced me to Wubi, it seemed almost magical how I could simply install ubuntu on my system and have windows treat it just like any other software! That spared me the hassle of creating a separate partition by rearranging my data somehow (which would have been a rather difficult process in my circumstances).

There was simply no reason for me to look back now. I installed Ubuntu and now for the past 1 week I have not looked at Windows Vista even once on my laptop. It’s not that I haven’t worked on linux before, as I have told you that I have worked on several distros for experimenting and learning purposes in the past, but after having worked on Windows Vista for about a year and then shifting to Ubuntu truly helped me see the incredibly huge difference myself. Ubuntu is simply miles ahead of Windows Vista (now I am not going to go into an argument, this is only a matter of personal belief), it is really cool and so swift, It’s almost as if I have upgraded my memory!!!

Only after using Ubuntu have I realized again that 1GB is indeed a lot of memory! In fact this reminded me about my first computer which had 32MB of RAM! of which I wrote an entry yesterday describing a comical incident I had when I tried to clean my data on my computer. Ubuntu is really a very good distro with all the tools one would need for a desktop. You can easily search for different applications from the add/remove applications dialog in the Ubuntu community and install them. Ubuntu also provides free security upgrades. Using Ubuntu one can very easily configure and manage not just a simple user desktop machine but even high end servers in a matter of minutes. With the really cool and interactive environment it provides, it really makes your desktop fun to interact with. The performance of Ubuntu over the desktop is really awesome.

My overall experience in these past days using Ubuntu has been really incredible and I would suggest each and every Windows user to atleast try Ubuntu using Wubi (if you haven’t already), it really doesn’t get any simpler than this and it will make your life really easy if you have difficulties, like I did, for separating partitions. In my opinion everyone should experience using Ubuntu at least once and see how they can very easily move to using Ubuntu while still being as productive (perhaps even more) as you were while you were on Windows! The Ubuntu community is also simply superb you will find great support there for all your problems (if you have any) and also find all the softwares you could need to do anything you would want to.

Do let me know what your opinions on the same are and what are your experiences using Ubuntu or any other distro for the same reason, and let me know how you liked this post. Until then, have a nice time guys and keep coding :).

Calculating a MD5, SHA1, SHA256, SHA384, SHA512 Hash in C#

Following my previous post in which I showed you how to calculate a corresponding Hash in Java, here I am giving another implementation through a simple function for calculating a Hash in C#.
Read More →

Calculating a MD5, SHA1, SHA256, SHA384, SHA512 Hash in Java

Hi, today I will show you with examples how to evaluate Hashes in Java programming languages. I hope this information comes in useful for many people.

Java which is my favorite programming language because of sheer simplicity, vastness and ease with which you can customize and extend existing libraries to suit your needs.
Read More →