题目
COMP30026_2025_SM2 Worksheet 7
多重下拉选择题
Complete the following statements about the languages given, over the alphabet Σ={b, e}: Let R = e*b*(ebb*)*(ε ∪ e), which is all strings that do not contain “bee”. The language A = L(R) is [ Select ] regular, R is not a correct regular expression not regular, R is not a correct regular expression regular, R is a correct regular expression not regular, R is a correct regular expression . Let B = {bee}. The language B is [ Select ] not regular regular . The language D = {w∈Σ* | w contains the substring bee exactly once} is [ Select ] regular, because D = A◦B◦A and regular languages are closed under concatenation unknown, because D = A◦B◦A, where one of the languages is not regular not regular, because D = A∪B, where one of the languages is not regular regular, because D = A∪B and regular languages are closed under concatenation unknown, because D = A∪B, where one of the languages is not regular not regular, because D = A◦B◦A, where one of the languages is not regular . The language K = {w∈Σ* | w contains n occurrences of the substring bee, where n≥1} is [ Select ] (D◦A◦B)* D* D∪B D*\A DD* , and is therefore [ Select ] unknown because at least one of the languages isn’t regular not regular because regular languages aren't closed under Kleene star not regular because at least one of the languages isn’t regular regular because regular languages are closed under concatenation and Kleene star regular because the regular languages are closed under union not regular because the regular languages aren’t closed under concatenation .
查看解析
标准答案
Please login to view
思路分析
Question restatement and options:
- We are given R = e*b*(ebb*)*(ε ∪ e) over Σ = {b, e}, and A = L(R) is ______; B = {bee} is ______; D = { w ∈ Σ* | w contains the substring bee exactly once } is ______; K = { w ∈ Σ* | w contains n occurrences of the substring bee, where n ≥ 1 } is ______, and then K is ______.
Option-by-option analysis for each part:
First part (A): 'A = L(R) is'
- Option: 'regular, R is a correct regular expression' (the provided correct choice in the list).
Analysis: The language described by R consists of all strings over {b,e} that do not contain the substring 'bee'. The given expression R = e*b*(ebb*)*(ε ∪ e) is a standard regular expression that generates exactly those strings by allowing any number of leading e's, then any number of b's, then a block structure (ebb*)* to prevent the forbidden pattern, and ending with either ε or an e. This matches the idea that the language is regular (regular expressions characterize regular languages), and R is indeed a valid regular expression for A. Therefore this option is correct for this part.
- Option: 'regular, R is not a correct regular expression'
Reasoning: This contradicts the explicit construction; since R is a formal regular expression that generates strings without 'bee', it i......Login to view full explanation登录即可查看完整答案
我们收录了全球超50000道考试原题与详细解析,现在登录,立即获得答案。
类似问题
Let L be a language defined as follows: L = { w | w ∈ {0,1}* && w does not have any 1s that are separated only by 2*n 0's where n ∈ ℕ\{0} } examples: "11", "101", "00", "010" are in L "1001", "10100001" are not in L Which of the following attempts to prove that L is a non-regular language provides a valid fooling set 'S' + algorithm to choose a distinguishing suffix for a pair of elements in S? For each of the following attempts, select the most specific answer from the respective drop-down. Attempt #1: S = { 1, 100, 10000, ...} = { 102m | m ∈ ℕ } ALG = " Given two elements from S 102i and 102j, where i < j, choose suffix 02i1 " Attempt #2: S = { 1, 10, 100, ...} = { 10m | m ∈ ℕ } ALG = " Given two elements from S 10i and 10j, where i < j: IF (i even and j odd || j even and i odd) -> Choose suffix "1" ELSE -> Choose suffix "0i1" " Attempt #3: S = { 0, 10, 100 } ALG = " Choose the suffix according to the following map of element pairings: (0,10) -> choose suffix "01" (0,100) -> choose suffix "1" (10,100) -> choose suffix "1" " 1: Attempt #1 2: Attempt #2 3: Attempt #3
Complete the following statements about the languages given, over the alphabet Σ={b, e}: Let R = e*b*(ebb*)*(ε ∪ e), which is all strings that do not contain “bee”. The language A = L(R) is [ Select ] not regular, R is not a correct regular expression not regular, R is a correct regular expression regular, R is not a correct regular expression regular, R is a correct regular expression . Let B = {bee}. The language B is [ Select ] regular not regular . The language D = {w∈Σ* | w contains the substring bee exactly once} is [ Select ] not regular, because D = A∪B, where one of the languages is not regular unknown, because D = A∪B, where one of the languages is not regular not regular, because D = A◦B◦A, where one of the languages is not regular unknown, because D = A◦B◦A, where one of the languages is not regular regular, because D = A∪B and regular languages are closed under concatenation regular, because D = A◦B◦A and regular languages are closed under concatenation . The language K = {w∈Σ* | w contains n occurrences of the substring bee, where n≥1} is [ Select ] D∪B DD* D* (D◦A◦B)* D*\A , and is therefore [ Select ] regular because regular languages are closed under concatenation and Kleene star not regular because the regular languages aren’t closed under concatenation not regular because regular languages aren't closed under Kleene star not regular because at least one of the languages isn’t regular unknown because at least one of the languages isn’t regular regular because the regular languages are closed under union .
Which one is correct?
In a consumer society, many adults channel creativity into buying things
更多留学生实用工具
希望你的学习变得更简单
加入我们,立即解锁 海量真题 与 独家解析,让复习快人一步!