Database Management Systems: Exam Questions and Solutions

Database Exam Solutions

2025 Q&A

(a) Q: A minimum cardinality of 0 specifies ______ type of participation.
Ans: Partial participation


(b)

Q: Let E1 and E2 be two entity sets with relationships R1 (1:M) and R2 (no attributes). What is the minimum number of tables required?
Ans: 2 tables


(c)

Q: Stud has 120 tuples and Enroll has 8 tuples. What are max and min tuples in Stud NATURAL JOIN Enroll?
Ans:

  • Maximum = 8
  • Minimum = 0

(d)

Q: Which normal form is considered adequate for normal relational database design?

Read More

NLP with Python: Morphological Analysis and N-Grams

NLP Tasks with NLTK

Aim

Write a Python program to:

  • Perform morphological analysis using the NLTK library.
  • Generate n-grams using the NLTK n-grams library.
  • Implement n-gram smoothing.

Description

  1. Morphological Analysis: This involves analyzing word structures to understand meaning and grammatical properties. NLTK provides tools like stemming and lemmatization for this purpose.
  2. N-Grams Generation: N-grams are contiguous sequences of n items from a text. NLTK provides functions to generate these from tokenized
Read More

Enterprise Software Platforms: Architecture and Best Practices

Enterprise Software Platform (ESP)

An Enterprise Software Platform (ESP) is an integrated, enterprise-wide environment of software, services, data, security, and governance used to run core business processes. It supports automation, integration, analytics, collaboration, scalability, and compliance across departments.

Platform Goals

  • Business alignment and operational efficiency
  • Agility, standardization, and reusability
  • Security and digital transformation

Key Components and Requirements

Major components

Read More

Python String and List Built-in Functions Reference

Python String Built-in Functions

Case Conversion Functions

upper()

👉 Definition: Converts all characters in a string to uppercase. It returns a new string without modifying the original.

👉 Example: "hello".upper() # "HELLO"


lower()

👉 Definition: Converts all characters in a string to lowercase.

👉 Example: "HELLO".lower() # "hello"


title()

👉 Definition: Capitalizes the first letter of every word and converts the remaining letters to lowercase.

👉 Example: "hello world".title() # "Hello World"

Read More

Greedy Strategy and Dynamic Programming Algorithms

Module 2: Greedy Strategy

1. Huffman Coding (Data Compression)

Definition: A greedy algorithm used for lossless data compression. It assigns variable-length codes to characters based on their frequency.

Working Principle:

  1. Count the frequency of each character.
  2. Place characters in a priority queue (Min-Heap) based on frequency.
  3. Pick two nodes with the lowest frequencies and create a new internal node with the sum of their frequencies.
  4. Repeat until only one node (the root) remains.
  5. Assign ‘0’ to the left
Read More

AI, ML, and DL: Core Concepts and Relationships

AI, ML, and DL: Core Concepts

Correlation: AI, ML, and DL

Artificial Intelligence (AI), Machine Learning (ML), and Deep Learning (DL) are interconnected fields, each building upon the other, but they are not synonymous. AI is the broader concept of machines being able to carry out tasks in a way that we would consider “intelligent.” ML is a subset of AI that focuses on the development of algorithms that allow computers to learn from and make predictions or decisions based on data. DL is a subfield

Read More