Wednesday 19 November 2014

COMPUTER NETWORKS

An Ebook on COMPUTER NETWORKS is available for FREE download here. The book has the following salient features.

  1. Detailed explanation of theory on certain topics.
  2. Over 100+ solved questions in computer networks of previous year papers(starting from 2008) with detailed explanation.
  3. Important formulae.
  4. Important URLs where MCQ's in computer networks are available.
Overall a very useful book for your learning reference in Computer Networks.

Click here on the following link, complete a small survey questionnaire and then download....

DOWNLOAD COMPUTER NETWORKS - EBOOK

Happy downloading and reading.

Monday 10 November 2014

IP ADDRESS AND ITS DIFFERENT CLASSES

IP address is the short form for Internet Address. These help to uniquely identify the hosts on the internet. The data which is sent over the network is delivered to the correct host with the help of the IP address.There are two versions of IP addresses available. IPv4 and IPv6. Let us talk about IPv4 now.

IPv4


IPVersion 4 addresses consist of 32 bits(0 through 31) partitioned into four groups of eight bits each. Each of this group is called an octet. It will be very difficult to understand and decipher the IP addresses if they were represented in the binary form and so they are reprsented in decimal form. Four decimal numbers separated by a dot, each standing for one octet. So, for example an IP address would look like this, 206.172.180.100.

  • IP address consist of 32 bits.
  • Each grouped into 4 groups of eight bits each.
  • Each of the eight bits are referred to as octets.

IP addresses are grouped into five classes class A, class B, class C, class D and class E. In order to differentiate between all these classes, we have to observe the first four bits of the first octet of the IP address.

CLASS A:

If the first bit is 0, then the IP address belongs to Class A. Class A addresses begins with a decimal number ranging from 0 to 127.Both 0 and 127 are reserved. So the first octet’s bit representation.

X X X X X X X X X - First octet's bit position
0 X X X X X X X X - Class A address representation
Each X stands for a bit which can be 0 or 1. For class A addresses the first bit would be a zero only.

CLASS B:
If the first two bits are 10, then the IP address belongs to class B. Class B addresses begins with a decimal number ranging from 128 to 191.
X X X X X X X X - First octet's bit position
1 0 X X X X X X - Class B address representation

The lowest class B address would be 1 0 0 0 0 0 0 0. The decimal equivalent of the same is 128. The highest class B address would be 1 0 1 1 1 1 1 1. The decimal equivalent of the same would be 191. That is why the decimal number range is between 128 to 191.

CLASS C:
If the first three bits are 110, then the IP address belongs to class C. Class C addresses begin with a decimal number ranging from 192 to 223.
X X X X X X X X – The first octet’s eight bits
1 1 0 X X X X X - Class C address representation

The lowest class C address would be 1 1 0 0 0 0 0 0. The decimal equivalent of the same is 27+26 = 192. The highest class C address would be 1 1 0 1 1 1 1 1. The decimal equivalent of the same is = 223.

CLASS D:
If the first four bits are 1110, then the address is class D address. Range of values from 224 to 229.

X X X X X X X X – The first octet’s eight bits
1 1 1 0 X X X X – Class D address
The lowest address would be 1 1 1 0 0 0 0 0. Decimal equivalent of the same is 128 + 64 + 32 = 224. Highest class D address would be 1 1 1 0 1 1 1 1. Again decimal equivalent of the same would be 128 + 64 + 32 + 8 + 4 + 2 +1 = 239. Class D addresses are used for multicasting.

CLASS E:
If the first four bits are 1111, then the address is a class E address. Range of decimal numbers ranging from 240 to 255.

X X X X X X X X – The first octet’s eight bits
1 1 1 1 1 1 1 1 – Class E address.
Lowest address = 1 1 1 1 0 0 0 0 = 128 + 64 + 32 + 16 = 240
Highest address = 1 1 1 1 1 1 1 1 = 128 + 64 + 32 + 16 + 8 + 4 + 2 + 1 = 255

STEPS TO FIND OUT THE CLASS OF IP ADDRESS


Given a IP address consider only the first octet. The rest of the octets can be of any value. That should not be of a concern in identifying the class of IP address. When we consider the first octet, there are two ways of identifying the class of IP address. One is to remember the decimal range of values for each class.
  1. Class A - 0 to 127
  2. Class B - 128 to 191
  3. Class C - 192 to 223
  4. Class D - 224 to 239
  5. Class E - 240 to 255
So if in the first octet the decimal number is given as 200.200.192.55 then the IP address belongs to class C because it falls in that range. But we might forget this sequence of numbers and that will be trouble for us. So, another way of working this out is to remember only the bit values for each of the class addresses.
  1. Class A - First bit is 0
  2. Class B - First two bits 1 0
  3. Class C - First three bits 1 1 0
  4. Class D - First four bits 1 1 1 0
  5. Class E - First four bits 1 1 1 1
So, given any IP address convert the first octet's decimal number to the binary equivalent. Look at the first few bits and decide the class of the IP address.

1. In IPv4, the IP address 200.200.200.200 belongs to
(A) Class A
(B) Class B
(C) Class C
(D) Class D
Ans :- C
Explanation:- Consider only the first octet's decimal value. Ignore the rest. The first octet value is 200. Convert the same to binary equivalent. It is 11001000. If the converted bit equivalent has less than 8 bits, then fill its left side with 0's and bring it to a count of 8 bits. The first 3 bits are 110 here and so this IP address belongs to class C address. So the answer is C. This question is from December 2013 - Paper III.

2. In classful addressing, the IP address 190.255.254.254 belongs to
(A) Class A
(B) Class B
(C) Class C
(D) Class D
Ans:- B
Explanation:- Again consider only the first octet. The value there is 190. Convert it into binary equivalent. It is 1011 1110. Look at the first two bits. It is 10. So it is class B address and so the correct answer is B. This question is from June 2013 - Paper II.

3. In classful addressing, the IP address 123.23.156.4 belongs to __________class format.
(a) A
(b) B
(c) C
(d) D
Ans:- A
Explanation:- Consider the first octet. The value is 123. The binary equivalent is 111 1011. There are only 7 bits. Add a zero in the high order bit. 0111 1011. The first bit is 0 and so the class address is A.This question is from December 2012 - Paper III.

4. IP address in class B is given by:
(A) 125.123.123.2
(B) 191.023.21.54
(C) 192.128.32.56
(D) 10.14.12.34
Ans:- B
Explanation:- You should be in a position to explain it on your own by now!!.

Dependency Preservation Decomposition

December 2010 - Question No 17

The dependency preservation decomposition is a property to decompose database schema D, in which each functional dependency X → Y specified in F,

(A) appeared directly in one of the relation schemas Ri in the decomposed D.
(B) could be inferred from dependencies that appear in some Ri.
(C) both (A) and (B)
(D) None of these

Explanation:- The question itself requires a bit of explanation. It is not enough if you just know what is the right answer but you must also know why it is the right answer. The explanation would be a bit lengthy. Let us first dissect the question and explain some terms in terms of DBMS.

Decomposition - This means replacing a relation with a collection of smaller relations.

Relation - Relation is known as Table.

Relation Schema - This is known as Table definition. Relation Schema for a "student" relation can be shown in the following way:
Student(FirstName,LastName,DOB,Gender,Course,Regno,Address)

Definition of Dependency preservation decomposition:-
Each FD specified in F either appears directly in one of the relations in the decomposition, or be inferred from FDs that appear in some relation.

Let us consider an example for Dependency preservation

Let R be a relation R(A B C D)
Let there be 3 functional dependencies.
FD1: A->B
FD2: B->C
FD3: C->D
Let the relation R be decomposed into two more relations.
R1(A B C)  :  R2(C D)
Let us first consider the relation R1(A B C). Here between A and B the functional dependency FD1 is preserved. Between B and C, FD2 is preserved.
Let us now consider the second relation R2(C D). Between C and D the FD, FD3 is preserved. So in the two relations R1 and R2, all the 3 functional dependencies are preserved.

Let us consider an example for Non-dependency preservation

Let R be a relation R(A B C D) Let there be again 3 functional dependencies.
FD1:A->B
FD2:B->C
FD3:C->D
Let the relation be decomposed into two more relations>
R1(A C D) R2(B C)
Let us first consider the relation R1(A C D). There is no FD between A and C. There is a FD3 between C and D.
Now let us consider the second relation R2(B C). There is FD2 between B and C.
So, the two relations only support only FD's FD2 and FD3. FD1 is not supported. So these relations does not preserve dependency.
Generally there are three desirable properties of a decomposition.

  1. Lossless
  2. Dependency preservation
  3. Minimal redundancy
The above question was based on dependency preservation decomposition. This example has been taken from the dependency preservation presentation by Jason Allen. The explanation is quite good there.

SUMMARY:-

The dependency preservation decomposition is a property to be considered for decomposing a relation into two or more smaller relations. The functional dependency X->Y specified in F can appear directly in one of the relation schemas Ri in the decomposed D or it could be inferred from dependencies that appear in some Ri. So the answer for this question is C.

Ans:-C

Thursday 6 November 2014

TOP PAID IPHONE APPS

As of 30th october 2014, the following are the top paid and free iphone apps. I have always been interested in what kind of apps are generously downloaded by users. Given below is a overview of the top apps along with what the app does.

1. Five night at Freddy's

This is a game developed by Scott Cawthon. It is a point-and-click horror game. The goal is for a player to survive the night at Freddy Faber's pizza where you are appointed as a night guard. The main attraction of the shop is Freddy Faber and two of his friends who are animatronic robots. They are programmed to please the crowds but in the night their behaviour becomes somewhat unpredictable. Seated in a room with a security camera, you are supposed to safeguard yourself from the robots.

2. Minecraft

It is a video game originally developed by Swedish programmer Markus "Notch" Persson and later developed and published by the Swedish company Mojang. You can use blocks to build something very imaginative in this game.

3. Heads Up!

It is the game that Ellen DeGeneres plays on her show. You have to guess the word on the card that is on your head from your friend's clues before the timer runs out. You hold the phone in such a way that your friends are able to see the word but you are not able to. You will have to guess the word based on your friends clues. There are different decks of cards including celebrities, movies, animals, characters etc.

4. Plague Inc

This is an iOS and Android strategy video game, developed by one-man developer Ndemic Creations. The players has to create and evolve a pathogen in an effort to destroy the world with a deadly plague. The game uses a model to simulate and spread the severity of the plague.

Afterlight

It is called UFO:Afterlight. This is a strategy computer game. It is the third in altar's UFO series. It is played in two parts. The first part is to claim territory,build structures, etc. The second part is , up to seven soldiers may be equipped and deployed to accomplish a goal in mission.

6. Swype-Keyboard

This is the first non-game app in the list. It is virtual keyboard for touch screen smartphones and tablets originally developed by Swype Inc. It is claimed to be the fastest and most intuitive keyboard on the planet. It offers predictive text keyboard with continuous gesture typing, personal dictionary, backup and sync.

7. SB for Vine

It is a app which is the first soundboard made of famous vine quotes. vine quotes are quotes made by famous personalities. Soundboard would actually play the quote. You can add your own quotes also there.

8. Geometry Dash

It is a fast-paced game full of fun and unpredictability.

9. Sleep cycle alarm clock

It is an intelligent alarm clock(unlike the usual ones), and wakes you in the lightest sleep phase, the natural way to wake up feeling rested and relaxed. It helps millions of people to wake up rested.

10. Buddyman

It is a game and can be a best stress reliever too. You can hit buddy man with bats and axes, shoot him with pistols and rifles, explode grenades and even drop a nuclear bomb.

Of all the top 10 paid apps, 8 are games. The only two non-game apps are the Swype and Sleep cycle alarm clock. For all budding app developers out there, take a cue from the top app performers. Later on the top free iphone apps.