Lex Program For checking a valid URL
Problem: Write a Lex program for checking a valid URL.
Lex is a computer utility that generates some lexical analyzers. Lex reads a stream of characters as input specifying the lexical analyzer and give source code as the output implementing the lexer in the C programming language.
Prerequisite: Flex (Fast Lexical Analyzer Generator)
Input: geeksforgeeks Output: INVALID URL Input: https://www.geeksforgeeks.org Output: VALID URL
Attention reader! Don’t stop learning now. Get hold of all the important CS Theory concepts for SDE interviews with the CS Theory Course at a student-friendly price and become industry ready.