29 votes 29 votes In some programming language, an identifier is permitted to be a letter followed by any number of letters or digits. If $L$ and $D$ denote the sets of letters and digits respectively, which of the following expressions defines an identifier? $(L + D)^+$ $(L.D)^*$ $L(L + D)^*$ $L(L.D)^*$ Theory of Computation gate1995 theory-of-computation regular-expression easy isro2017 + – Kathleen asked Oct 8, 2014 • recategorized Apr 25, 2021 by Lakshman Bhaiya Kathleen 13.3k views answer comment Share Follow See all 5 Comments See all 5 5 Comments reply Show 2 previous comments Ajitgate21 commented Oct 20, 2022 reply Follow Share a letter followed by( any number of( letters or digits)*). 0 votes 0 votes amitarp818 commented Aug 9, 2023 reply Follow Share Why can it not be D?? 0 votes 0 votes Prashant_Dubey commented Dec 12, 2023 reply Follow Share identifier is permitted to be a letter followed by any number of letters or digits. @amitarp818 Read this line given in the ques. 1 votes 1 votes Please log in or register to add a comment.
1 votes 1 votes (c)L(L + D)* anonymous answered May 7, 2017 anonymous comment Share Follow See all 0 reply Please log in or register to add a comment.
1 votes 1 votes Ans: C rishu_darkshadow answered Sep 16, 2017 rishu_darkshadow comment Share Follow See 1 comment See all 1 1 comment reply Sankha Narayan Bose commented Mar 26, 2018 reply Follow Share C.. 0 votes 0 votes Please log in or register to add a comment.
0 votes 0 votes Letter followed by any number of letters (or) digits L(L ∪ D)* varunrajarathnam answered Aug 20, 2020 varunrajarathnam comment Share Follow See all 2 Comments See all 2 2 Comments reply raja11sep commented Jul 14, 2021 reply Follow Share Unnecessary. 0 votes 0 votes raja11sep commented Jul 15, 2021 reply Follow Share @varunrajarathnam It’s really helpful.. thanks, bro. 0 votes 0 votes Please log in or register to add a comment.
0 votes 0 votes if that is the condition then i can see this problem as a starting with letter problem so for that easily we can construct a finite automata or directly we can write L*(L+D)* so starting with L there can be anything any number of digit or letter. arkaprabha1012 answered Aug 22, 2020 arkaprabha1012 comment Share Follow See 1 comment See all 1 1 comment reply raja11sep commented Jul 14, 2021 reply Follow Share L*(L+D)* means empty string(epsilon) is there, how identifier name can be empty? So there must be at least one character right. If an identifier is there with a single character then it must be a letter. 0 votes 0 votes Please log in or register to add a comment.