Add a single-line input field with validation for a phone number in the format (123) 456-7890 using the pattern attribute.
HardProblem Statement
Add a single-line input field with validation for a phone number in the format (123) 456-7890 using the pattern attribute.
Sample Input
A phone input field with validation.
Sample Output
The webpage displays an input field that only accepts phone numbers in a specific format.
Limits
Time: 2s · Memory: 256 MB
Code Editor
Log in to submit00:00
Try your code in this preview. Submit marks it done.
<!doctype html>
<html></html>
Document
To view the HTML changes, please type the code within the editor