The Gateway to Computer Science Excellence

First time here? Checkout the FAQ!

x

0 votes

3. Consider these 2 statements:

S1: LR = L, if and only if L is the language of palindromes.

where LR is obtained by reversing all the strings of L.

S2: | L1∙ L2 | = | L1 | × | L2 |

Relation?

(a) Both are F (b) Both are T

(c) S1 → T, S2 → F (d) S1 → F, S2 → T

S1: LR = L, if and only if L is the language of palindromes.

where LR is obtained by reversing all the strings of L.

S2: | L1∙ L2 | = | L1 | × | L2 |

Relation?

(a) Both are F (b) Both are T

(c) S1 → T, S2 → F (d) S1 → F, S2 → T

0 votes

For Statement 1:-

you know that **w=w ^{R} ===> it is a palindrome string.**

let L= Collection of Strings which are palindromes ===> L^{R} = reversing each string in L = string in L

∴ S1 is TRUE.

For Statement 2 :-

| L_{1}.L_{2 }| = |L_{1}| X | L_{2} |

LHS = **concatenate L _{1} string, L_{2} String and take the length of resultant**

RHS = **Take the length of string in L _{1}, length of string in L_{2} and multiply them **

Obvisiouly it is a relation....but not a function,

0

take L_{1} = {0,01,10,111}, L_{2}={1010,1011,10101}

| L_{1} . L_{2} | = | {0,01,10,111} . {1010,1011,10101} | ===> have 12 elements

0 . 1010 ===> | L_{1} . L_{2} | = 5 , | L_{1} | X | L_{2} | = 5

0 . 1011 ===> | L_{1} . L_{2} | = 5 , | L_{1} | X | L_{2} | = 5

0 . 10101 ===> | L_{1} . L_{2} | = 6 , | L_{1} | X | L_{2} | = 5

01 . 1010 ===> | L_{1} . L_{2} | = 6 , | L_{1} | X | L_{2} | = 8

01 . 1011 ===> | L_{1} . L_{2} | = 6 , | L_{1} | X | L_{2} | = 8

01 . 10101 ===> | L_{1} . L_{2} | = 7 , | L_{1} | X | L_{2} | = 10

10 . 1010 ===> | L_{1} . L_{2} | = 6 , | L_{1} | X | L_{2} | = 8

10 . 1011 ===> | L_{1} . L_{2} | = 6 , | L_{1} | X | L_{2} | = 10

10 . 10101 ===> | L_{1} . L_{2} | = 7 , | L_{1} | X | L_{2} | = 10

111 . 1010 ===> | L_{1} . L_{2} | = 7 , | L_{1} | X | L_{2} | = 12

111 . 1011 ===> | L_{1} . L_{2} | = 7 , | L_{1} | X | L_{2} | = 12

111 . 10101 ===> | L_{1} . L_{2} | = 8 , | L_{1} | X | L_{2} | = 15

the relation look like as {(5,5), (6,5), (6,8), (6,10), (7,10) , (7,12), (8,15) } but it is not a function

sorry for that, i will edit my answer.

- All categories
- General Aptitude 1.5k
- Engineering Mathematics 7.3k
- Digital Logic 2.7k
- Programming & DS 4.9k
- Algorithms 4.2k
- Theory of Computation 5.4k
- Compiler Design 2.1k
- Databases 4k
- CO & Architecture 3.5k
- Computer Networks 4.2k
- Non GATE 1.4k
- Others 1.5k
- Admissions 568
- Exam Queries 566
- Tier 1 Placement Questions 23
- Job Queries 69
- Projects 18

48,449 questions

52,747 answers

183,346 comments

68,219 users