• ¿Documento equivocado? Cámbialo gratis
  • Escrito por estudiantes que aprobaron
  • Inmediatamente disponible después del pago
  • Leer en línea o como PDF
Vender
¿Dónde estudias?
Tu idioma
Document preview thumbnail
Vista previa 4 fuera de 53 páginas
Examen

COS2601 Assignment 03 Due August 2026

Document preview thumbnail
Vista previa 4 fuera de 53 páginas

Comprehensive Study Material; Expert Verified & Exam-Ready This assignment package has been carefully developed to support serious academic preparation. Each solution is thoroughly researched, clearly explained, and backed by credible references giving you not just the answers, but a genuine understanding of the underlying concepts. The material is structured for clarity, making even complex topics approachable without sacrificing depth or accuracy. Whether you're consolidating your knowledge or preparing under time pressure, these resources are designed to help you walk into any exam with confidence.

Vista previa del contenido

UNIVERSITY OF SOUTH AFRICA
Department of Computer Science


⋄ ⋄ ⋄ ⋄ ⋄ ⋄ ⋄ ⋄ ⋄⋄


COS2601: Theoretical Computer Science II

Assignment | Year Module

⋄ ⋄ ⋄ ⋄ ⋄ ⋄ ⋄ ⋄ ⋄⋄




COS2601
Module Code:
Theoretical Computer Science II
Module Name:
3
Assignment Number:




Submitted in partial fulfilment of the require-
ments for Theoretical Computer Science II, UNISA

,UNISA | COS2601 Theoretical Computer Science II



Question 1 [10 marks]


1(a) Let S be a set of strings on {a, b} with S = {ba, bb, baa, bab, aba}. For each of the follow-
ing strings, state whether or not it is a word in S ∗ . Justify your answer.


(i) baabababb


The set is:



S = {ba, bb, baa, bab, aba}


A word belongs to S ∗ if it can be formed by concatenating zero or more words from S.

Consider:



baabababb


We try to divide it into words from S:



baabababb = baa · bab · b


The first two parts are valid:



baa ∈ S




bab ∈ S


However:



b∈
/S


Therefore, this decomposition does not work.

Try another possible decomposition:


Page 2 of 53

,UNISA | COS2601 Theoretical Computer Science II




baabababb = ba · aba · babb


Although:



ba ∈ S


and



aba ∈ S


we have:



babb ∈
/S


No decomposition into complete words from S is possible.



/ S∗
baabababb ∈


(ii) babbaab


Consider:



babbaab


We can write:



babbaab = bab · baa · b


Although:



bab ∈ S



Page 3 of 53

, UNISA | COS2601 Theoretical Computer Science II


and



baa ∈ S


the remaining string is:



b∈
/S


Therefore:



/ S∗
babbaab ∈


Thus, neither of the two given strings is a word in S ∗ .


1(b) Provide an example of two sets of strings S and T on {a, b} such that:


S⊈T


and



S ∗ ∩ T ∗ = (S ∩ T )∗


Take:



S = {a}


and



T = {b}


Clearly:



S⊈T

Page 4 of 53

Libro relacionado
 image
Editorial: 1996 ISBN: 9783540620341 Edición: Desconocido

Información del documento

Subido en
27 de julio de 2026
Número de páginas
53
Escrito en
2025/2026
Tipo
Examen
Contiene
Preguntas y respuestas
$7.52

¿Documento equivocado? Cámbialo gratis Dentro de los 14 días posteriores a la compra y antes de descargarlo, puedes elegir otro documento. Puedes gastar el importe de nuevo.
Escrito por estudiantes que aprobaron
Inmediatamente disponible después del pago
Leer en línea o como PDF

Seller avatar
Los indicadores de reputación están sujetos a la cantidad de artículos vendidos por una tarifa y las reseñas que ha recibido por esos documentos. Hay tres niveles: Bronce, Plata y Oro. Cuanto mayor reputación, más podrás confiar en la calidad del trabajo del vendedor.
BeeNotes
4.1
(40)
Vendido
352
Seguidores
0
Artículos
1012
Última venta
1 semana hace



Por qué los estudiantes eligen Stuvia

Creado por compañeros estudiantes, verificado por reseñas

Calidad en la que puedes confiar: escrito por estudiantes que aprobaron y evaluado por otros que han usado estos resúmenes.

¿No estás satisfecho? Elige otro documento

¡No te preocupes! Puedes elegir directamente otro documento que se ajuste mejor a lo que buscas.

Paga como quieras, empieza a estudiar al instante

Sin suscripción, sin compromisos. Paga como estés acostumbrado con tarjeta de crédito y descarga tu documento PDF inmediatamente.

Student with book image

“Comprado, descargado y aprobado. Así de fácil puede ser.”

Alisha Student

Preguntas frecuentes