Your next chapter starts hereExplore admission guide

Previous Year Questions

Admission syllabus
Reset

Computer Science and Engineering

430 questions
2007-2008 · Question 1a Written Full paper
Programming / Data types, variables and operators Programming / Control statements and loops

1. (a) Write a program in $\text{C/C}^{++}$ to calculate the summation of the following series. [নিম্নলিখিত ধারাটির যোগফল নির্ণয়ের জন্য একটি $\text{C/C}^{++}$ প্রোগ্রাম লিখ। $1^2+2^2+3^2+\dots\dots\dots\dots\dots+n^2$]

Answer & solution / উত্তর ও সমাধান

\[\sum_{k=1}^n k^2=\frac{n(n+1)(2n+1)}6\]

#include <stdio.h>
int main(void) {
    long long n, sum = 0;
    if (scanf("%lld", &n) != 1 || n < 0 || n > 1000000) return 1;
    for (long long i = 1; i <= n; ++i) sum += i * i;
    printf("%lld\n", sum);
    return 0;
}
2007-2008 · Question 1b Written Full paper
Programming / OOP: inheritance

1. (b) What is inheritance? Give its real world example. [ইনহেরিটেন্স কি? ইহার একটি বাস্তব উদাহরণ দাও ।] (05)

Answer & solution / উত্তর ও সমাধান

Inheritance-এ derived class base class-এর accessible data ও behaviour পুনর্ব্যবহার করে এবং নতুন behaviour যোগ করতে পারে। উদাহরণ: Vehicle থেকে Car ও Bus।

#include <iostream>
class Vehicle {
public:
    void start() const { std::cout << "Started\n"; }
};
class Car : public Vehicle {
public:
    void drive() const { std::cout << "Driving\n"; }
};
int main() { Car c; c.start(); c.drive(); }
2007-2008 · Question 2a Written Full paper
Historical: Discrete Mathematics / Propositional and predicate logic

2. (a) Use a truth table to verify the equivalence $\neg(p \wedge q) \Leftrightarrow \neg(p \vee \neg q)$. [$\neg(p \wedge q) \Leftrightarrow \neg(p \vee \neg q)$ সমীকরণটি ইকুইভ্যালেন্স কিনা তাহা ট্রুথ টেবিলের মাধ্যমে দেখাও ।]

Answer & solution / উত্তর ও সমাধান
pqNOT(p AND q)NOT(p OR NOT q)
0010
0111
1010
1100

দুই column এক নয়। প্রশ্নে লেখা equivalence ভুল; De Morgan-এর সঠিক সূত্র:

\[\neg(p\land q)\equiv\neg p\lor\neg q\]

2007-2008 · Question 2b Written Full paper
Data Structure / Graphs (historical)

2. (b) Represent the following graph by a matrix. [নিম্নলিখিত গ্রাফটিকে একটি ম্যাট্রিক্স এর সাহায্যে প্রকাশ কর ।] (08)

Incomplete source data

Answer & solution / উত্তর ও সমাধান

Original graph image নেই, তাই তার নির্দিষ্ট adjacency matrix যাচাই করা যায় না। Vertex order v1,…,vn নিলে:

\[a_{ij}=\begin{cases}1,&v_i\to v_j\text{ edge থাকলে}\\0,&\text{অন্যথায়}\end{cases}\]

Undirected graph-এ matrix symmetric। Self-loop থাকলে diagonal entry 1। Original graph ছাড়া source-এর matrix-কে নিশ্চিত উত্তর বলা যাবে না।

2007-2008 · Question 3a Written Full paper
Data Structure / Data structure operations

3. (a) What is mean by the data structure? Montion the data structure operations [ডাটা স্ট্রাকচার বলতে কি বুঝায়? ডাটা স্ট্রাকচারের অপারেশন সমূহ উল্লেখ কর ।]

Answer & solution / উত্তর ও সমাধান
Operationকাজ
Traversalসব element visit
Insertionনতুন element যোগ
DeletionElement বাদ
Searchনির্দিষ্ট element খোঁজা
Sortনির্দিষ্ট order-এ সাজানো
Mergeদুই structure combine
2007-2008 · Question 3b Written Full paper
Data Structure / Stacks and expression evaluation Data Structure / Queues

3. (b) Define stack and queue with examples [উদাহরণসহ স্ট্যাক ও কিউ এর সংজ্ঞা দাও।] (08)

Answer & solution / উত্তর ও সমাধান
StackQueue
LIFO: last in, first outFIFO: first in, first out
Push/pop একই top-এEnqueue rear-এ, dequeue front-এ
উদাহরণ: call stack, undoউদাহরণ: print queue, BFS
2007-2008 · Question 4a Written Full paper
Database Management / Relations and data abstraction

4. (a) What is meant by the data abstraction? Mention the levels of Data abstraction. (ডাটা এবস্ট্রাকশন বলতে কি বুঝায়? ডাটা এবস্ট্রাকশনের বিভিন্ন স্তরগুলো উল্লেখ কর। (06)

Answer & solution / উত্তর ও সমাধান

Data abstraction ব্যবহারকারীকে অপ্রয়োজনীয় storage details থেকে আলাদা রাখে।

Levelঅর্থ
Physicalডেটা কীভাবে disk-এ সংরক্ষিত
Logicalকোন data, structure ও relationship আছে
View/externalনির্দিষ্ট ব্যবহারকারীর দেখা অংশ
2007-2008 · Question 4b Written Full paper
Database Management / Database concepts and DBMS Database Management / Data models and ER diagrams

4. (b) What are the different data models of database system? [ডাটাবেস সিস্টেমে কি কি রকম ডাটা মডেল আছে?]

Answer & solution / উত্তর ও সমাধান
  1. Relational model: tables, rows, columns।
  2. Hierarchical model: parent-child tree।
  3. Network model: record এবং multiple links।
  4. Entity-relationship model: conceptual entities ও relationships।
  5. Object-oriented model: objects ও classes।
  6. Object-relational model: relational-এর সঙ্গে object features।
2007-2008 · Question 5 Written Full paper
Database Management / Database concepts and DBMS

5. Define DBMS, Mention the advantages and disadvantage of DBMS over conventional file processing. [DBMS এর সংজ্ঞা লিখ। প্রচলিত ফাইল প্রসেসিং এর তুলনায় DMBS এর সুবিধা ও অসুবিধাগুলি লিখ।] (10)

Answer & solution / উত্তর ও সমাধান

DBMS হলো database সংজ্ঞা, সংরক্ষণ, query ও পরিবর্তন করার software; এটি integrity, access control, transactions এবং recovery পরিচালনা করে।

  1. নিয়ন্ত্রিত redundancy ও consistency।
  2. Constraints দিয়ে data integrity।
  3. Authorization ও access control।
  4. Transactions ও concurrent access।
  5. Backup এবং crash recovery।
  6. Data independence ও SQL query।

অসুবিধা: software/hardware ও administration খরচ, complexity, migration effort এবং central service failure-এর প্রভাব।

2007-2008 · Question 6a Written Full paper
Historical: Software Development / System analysis and feasibility

6 (a): System Analysis ও ডিজাইন বলতে কি বোঝ? Analysis ছাড়া কি সিস্টেম ডিজাইনের কাজ কি শুরু করা যায়?

Answer & solution / উত্তর ও সমাধান

System analysis হলো বর্তমান system, problem ও user requirements পরীক্ষা করে নতুন system কী করবে তা নির্ধারণ করা।

  1. Stakeholder interview ও observation।
  2. Existing process ও data flow পর্যালোচনা।
  3. Functional/non-functional requirements সংগ্রহ।
  4. Model, validate ও prioritise requirements।
  5. Requirements specification প্রস্তুত।

Design নির্ধারণ করে system কীভাবে তৈরি হবে; analysis মূলত কী দরকার তা নির্ধারণ করে।

2007-2008 · Question 6b Written Full paper
Historical: Software Development / System analysis and feasibility

6 (b). Describe the steps in Feasibility Analysis. [ফিজিবিলিটি এনালাইসিস এর ধাপ গুলো বর্ণনা কর।] (10)

Answer & solution / উত্তর ও সমাধান
  1. Problem ও scope নির্ধারণ।
  2. Alternative solution চিহ্নিত করা।
  3. Technical feasibility যাচাই।
  4. Economic cost-benefit analysis।
  5. Operational, legal ও schedule feasibility যাচাই।
  6. Risk তুলনা করে recommendation ও feasibility report তৈরি।
2007-2008 · Question 8 Written Full paper
Operating System / Processes and scheduling

8. What do you mean by a process of an operating system? What are the states of a process? [একটি অপারেটিং সিস্টেমের প্রসেস বলতে কি বুঝায়? একটি প্রসেসের স্টেটগুলি কি কি?] (13)

Answer & solution / উত্তর ও সমাধান

Process হলো execution-এ থাকা program।

Stateঅর্থ
Newতৈরি হচ্ছে
ReadyCPU পাওয়ার অপেক্ষা
RunningCPU-তে চলছে
Waiting/blockedI/O/event-এর অপেক্ষা
TerminatedExecution শেষ

প্রধান transition: New → Ready → Running; Running → Ready (preemption), Running → Waiting (I/O), Waiting → Ready (event complete), Running → Terminated।

2007-2008 · Question 9 Written Full paper
Operating System / Deadlocks

9. Explain briefly the causes of deadlock in the operating system? (অপারেটিং সিস্টেমের ডেড লক এর কারণগুলি সংক্ষেপে বর্ণনা কর।) (13)

Answer & solution / উত্তর ও সমাধান

Deadlock-এ processes একে অন্যের held resource-এর জন্য অনির্দিষ্টকাল অপেক্ষা করে। প্রয়োজনীয় চারটি Coffman condition:

  1. Mutual exclusion
  2. Hold and wait
  3. No preemption
  4. Circular wait

উদাহরণ: P1 R1 ধরে R2 চায়, P2 R2 ধরে R1 চায়। শর্তগুলোর অন্তত একটি প্রতিরোধ করে deadlock prevention করা যায়।

2007-2008 · Question 10a Written Full paper
Microprocessor & Microcomputer / Bus systems and addressing Microprocessor & Microcomputer / Memories and storage

10. (a) How many address lines are required to address a 1 Tera memory locations? [1 Tera memory locations কে address করার জন্য কতটি এড্রেস লাইন প্রয়োজন হয়।] (03)

Answer & solution / উত্তর ও সমাধান

\[n=\lceil\log_2N\rceil=\boxed{40}\]

Binary অর্থে 1 tera location = 2^40। Decimal 10^12 location ধরলেও ceiling(log2 N) = 40।

2007-2008 · Question 10b Written Full paper
Microprocessor & Microcomputer / Instruction sets and assembly language

10. (b) Classify the instruction set of microprocessors? [মাইক্রোপ্রসেসরের ইন্সট্রাকশন সেট এর শ্রেণি বিন্যাস কর।] (03)

Answer & solution / উত্তর ও সমাধান
Class8085 example
Data transferMOV, MVI, LDA
ArithmeticADD, SUB, INR
LogicalANA, ORA, XRA, CMP
BranchJMP, JZ, CALL, RET
Stack, I/O ও machine controlPUSH, POP, IN, OUT, HLT