Showing posts with label regular. Show all posts
Showing posts with label regular. Show all posts

Saturday, 12 October 2013

Validating date (DD/MM/YYYY) Java

The task is to create a tool in Java that takes a string as an input and validates if it is in date format (dd/mm/yyyy).

The source-code for the tool (Java 7) :

| Advertisement |

Validating an e-mail string Java

The assignment is to write code that validates if the input string can be an e-mail.

The code for tool is given below (Java7) :
| Advertisement |

Friday, 11 October 2013

Validate password string Java

The task is to create a tool in Java that takes a string as an input and validates if it can be a password.

The source-code for the tool (Java 7) :

| Advertisement |

Validate a username string Java

The task is to create a tool in Java that takes a string as an input and validates if it can be a username.

The source-code for the tool (Java 7) :

| Advertisement |

Finding a numeric string from an alphanumeric string Java

The assignment is to develop a tool in Java that takes an alphanumeric string as input and finds numeric sub-strings.

Simply, we need to print all the indexes where the numeric strings occurs in the alphanumeric string.

The source-code for the tool (Java 7) :
| Advertisement |

Thursday, 10 October 2013

Matching a word in a string java

The assignment is to develop a tool in Java that takes two inputs - the text string and the pattern; and finds all the matches of pattern in the text string.

Simply, we need to print all the indexes where the pattern occurs in the text string.

The source-code for the tool (Java 7) :


| Advertisement |