Search
⌘K

Leetcode 468. Validate IP Address

Determine whether a string is a valid IPv4 (four dot-separated decimal octets 0–255 with no leading zeros) or IPv6 (eight colon-separated groups of 1–4 hexadecimal digits, case-insensitive) address, and return "IPv4", "IPv6", or "Neither".

Asked at:

Meta


Question Timeline

See when this question was last asked and where, including any notes left by other candidates.

Early December, 2025

Meta

Mid-level

Late January, 2025

Meta

Mid-level

Comments

Your account is free and you can post anonymously if you choose.