Matching IP addresses


show more Matching IP addresses provides you with in-depth training on Developer. Taught by Kevin Skoglund as part of the Using Regular Expressions show less
please wait ...

Matching IP addresses

In this movie, we'll write a regular expression to match IP addresses, and in the process, we'll explore some important points about how regular expressions work with matching numbers. Let's take a look at how an IP address typically looks. It's typically made up of four different parts; each one is a number separated by a decimal, and those numbers can range between 0 and 255. So the lowest number we can have would be 0.0.0.0, and the highest number we can have will be 255.255.255.255. And it would be some number in between there.

Typically, it might look something like this: 67.52.159.38. You can also have leading zeros in front of there. It's perfectly acceptable to have 067.052.159.038. Often they're omitted, but let's not forget about this case. So that's pretty simple, right? Each of those four parts can be a number between 0 to 255. Let's take a stab by writing an expression for it, and see what problems we run into. So to begin with let's tu...

Matching IP addresses
Video duration: 7m 10s 5h 36m Intermediate

Viewers:

Matching IP addresses provides you with in-depth training on Developer. Taught by Kevin Skoglund as part of the Using Regular Expressions

Subject:
Developer
Software:
Regular Expressions
Author:
please wait ...