March 29, 2015

VIRUS, TROJAN | What is the difference?

Everyone (almost) of us have heard of Computer Viruses and Trojans and probably faced a fair (unfair?) share of problems because of them. But, how much do you really know about these Spyware? Here's a quick article
to understand all about them.

Security,Virus,Trojan|Swaroops blog

March 23, 2015

New Sports Bike in town | KTM RC 390

  If you are a Motor Bike enthusiast, then you most likely would have heard about the Austrian manufacturer KTM. You might have even heard about the Duke 390 which was released a couple of years ago. A new Sports bike is coming up in the same lineup. So, here is the everything you need to know about the all new supersport bike from KTM, the RC 390.

KTM RC 390 | Swaroop's Blog

February 26, 2015

YouTube's Most Watched Videos | TOP 10

Psy Gentleman | Swaroop's BlogEver since Psy's Gangnam Style has crossed 2 Billion views, the only reason i go to that video is to check the number of views. Many of you might be doing the same thing. And, quite recently psy's other video, Gentleman has crossed the 800 Million mark, so, its time for another snapshot of the current top 10 videos of YouTube. The list is really important and shed light on the interest patterns of the people and what kind of things attract us the most.
To look at the list from last year, here.

Not surprisingly all of them are Music Videos, because we all love music, except for the Charlie video which we absolutely love and adore.
So, Let's see how each of these videos is doing starting with #1, Gangnam Style.

February 16, 2015

C Program for decrypting Caesar's Cipher

Caesar's cipher is one of the most popular encryption techniques in Cryptography. It is also referred to as Caesar's shift cipher or simply Shifting cipher.  It is said to be widely used in private communications of Julius Caesar. The encryption of the plain text is done by shifting the letters by a previously agreed number. So, after a shift of 2, 'a' becomes 'c', 'b' becomes 'd' and so on..

This article will show you a program that can be used to decrypt the cipher text encrypted using this method. To decrypt, you need to know the key which is the shift used to encrypt. Using the key we'll just do the reverse of encryption to get the Plain text. And, we'll program all that.

For example, the following is a decryption with a left shift 3.
Ciphertext: QEB NRFZH YOLTK CLU GRJMP LSBO QEB IXWV ALD
Plaintext:  THE QUICK BROWN FOX JUMPS OVER THE LAZY DOG
The following is the function implemented in C Programming for the decrytpion.

February 01, 2015

C Program that prints its own Source Code | C Programming Quine

Quine in programming terms is a program which outputs its own Source code. These are self-replicating programs and are very popular in the programming community. So, in this article we will see how we can achieve this.
           This problem may sound complex, but this is actually quite easy and simple. So, the way we proceed with this is by opening the source file from the program and print out each and every character.
Sounds simple, doesn't it? Lets code it.
Things you need to know for this : Usage of File Pointers
C Programming - Swaroop's Blog
Procedure: Lets break down the approach step by step
  1. Open the current file (fopen()) using a file pointer (in Read Mode)
  2. Read characters one after the other and print them until you reach the end of the file (EOF)
  3. Close the file
To open the file we'll use the fopen() function which takes in two parameters, the location of the file and mode of opening (Read/Write). Fortunately for us, there is a macro in C, to give us file's location, called  _FILE_  macro. Using this we can get the location/path of the current file.