Recent questions tagged goclasses-cs-dpp-day-377

1 1 vote
2 2 answers
174
174 views
Consider the relations:$\mathrm{Users(username, name, email, password, address)}$and$\mathrm{FriendsWith(username, username2, sincewhen)}$.A friendship tuple indicates th...
1 1 vote
1 1 answer
96
96 views
Consider the relations:$\mathrm{STUDENT(name,regno,gpa,level,dept)}$$\mathrm{COURSE(cno,cname,dept)}$$\mathrm{TAKE(regno,cno)}$Using only the basic relational algebra ope...
1 1 vote
1 1 answer
95
95 views
Consider $R(a,b)$ and $S(c,d)$.Which relational algebra expression is equivalent to:SELECT a, d FROM R, S WHERE R.a 10 AND R.b = S.c;Use only the basic operators.$\pi_{a...
1 1 vote
1 1 answer
91
91 views
Let $R$ and $S$ be union-compatible relations.Which expression computes $R\cap S$ using only union and set difference?$(R\cup S)-((R-S)\cup(S-R))$ $(R\cup S)-(R-S)$ $(R-S...
1 1 vote
1 1 answer
109
109 views
Consider $\text{parts(pno, pname, price)}$.Which relational algebra expression returns exactly the names of all parts whose price is greater than $\$200$?$\pi_{\text{pnam...
2 2 votes
1 1 answer
90
90 views
For languages $X,Y\subseteq\Sigma^*$, define$$X/Y = \{w:\exists y\in Y,\ wy\in X\}$$ Suppose $X$ is regular, but nothing is assumed about $Y$.Which statement is always tr...
0 0 votes
1 1 answer
69
69 views
Let $X$ and $Y$ be regular languages. Their symmetric difference is$$X\triangle Y=\{w:w\text{ belongs to exactly one of }X,Y\}$$. Which expression correctly represents $X...
2 2 votes
1 1 answer
74
74 views
Let $M$ and $N$ be two DFAs. Define$$Z=\{u_1v_1u_2v_2\cdots u_kv_k : k\ge0, ~u_i\in L(M), ~v_i\in L(N)\}.$$Which regular-language expression describes $Z$?$L(M)^*L(N)^*$ ...
1 1 vote
1 1 answer
65
65 views
Let $L$ be an arbitrary regular language over $\Sigma$, and define$$K=\{w\in\Sigma^*:w^Rw\in L\}$$.Which statement is correct?$K$ is always regular. $K$ is regular only i...
0 0 votes
1 1 answer
61
61 views
For an arbitrary language $L$, which of the following statements is correct?If $L^*$ is regular, then $L$ must be regular. If $L$ is nonregular, then $L^*$ must be nonreg...
To see more, click for the full list of questions or popular tags.