if i enter 153.18.8.105 the o/p should be 2568095849....for separation u can use strtok for separating.....