Bangladesh Competition Commission Programmer Written Exam: 2019 (DU)প্রশ্ন ও সমাধান
- Set by
- Bangladesh Competition Commission
- Post
- Programmer
- Exam date
- 2019
- Conducted by
- DU
- Questions
- 9 (0 MCQ, 9 written)
- Exam guide
- Government IT officer posts · সরকারি প্রতিষ্ঠানের আইটি পদ
- Programming · প্রোগ্রামিং 3
- Operating Systems · অপারেটিং সিস্টেম 2
- Software Engineering · সফটওয়্যার ইঞ্জিনিয়ারিং 2
- Algorithms · অ্যালগরিদম 1
- Database · ডেটাবেজ 1
Difference between compiler and interpreter with example?
Sign up free to see the model answer · উত্তর দেখতে বিনামূল্যে সাইন আপ করুন
What is operating System? What are the main components of operating System?
Sign up free to see the model answer · উত্তর দেখতে বিনামূল্যে সাইন আপ করুন
Briefly Describe Abstraction, Encapsulation.
Sign up free to see the model answer · উত্তর দেখতে বিনামূল্যে সাইন আপ করুন
What is multitasking and multithreading? What are the advantage threads over process?
Model answer
Multitasking: the OS's ability to run multiple programs/processes concurrently by rapidly switching the CPU between them, giving the illusion of simultaneous execution on a single CPU (or genuine parallel execution on multiple cores).
Multithreading: a single process divided into multiple threads (lightweight sub-units of execution) that run concurrently and share the same process's memory space (code, data, open files) — unlike multitasking's separate processes, which don't share memory by default.
graph TD
P[Process] --> T1[Thread 1]
P --> T2[Thread 2]
P --> T3[Thread 3]
T1 --- SM[(Shared Memory/Code/Data)]
T2 --- SM
T3 --- SM
Advantages of threads over processes:
- Faster creation & context switching: creating/switching a thread is cheaper than a process, since threads share the same address space.
- Responsiveness: if one thread blocks (e.g., waiting on I/O), other threads in the same process can continue running.
- Resource sharing: threads share code, data, and open file handles directly — no inter-process communication (IPC) overhead needed.
- Efficient multiprocessor use: multiple threads of one process can run truly in parallel across CPU cores.
Example: a web browser uses multithreading — one thread renders the page while another downloads images and another handles user input — all sharing the same process's memory, so switching between them is far cheaper than running three separate browser processes.
Exam takeaway: multitasking = multiple processes sharing CPU time; multithreading = multiple threads within one process sharing memory — threads trade isolation (a crashing thread can bring down the whole process) for speed and lower overhead.
Write a program in C to find the sum of following series: 1²+2²+3²+ ………... +n²
Sign up free to see the model answer · উত্তর দেখতে বিনামূল্যে সাইন আপ করুন
What is the difference between primary key and candidate key? Explain the foreign key with an example.
Sign up free to see the model answer · উত্তর দেখতে বিনামূল্যে সাইন আপ করুন
A prim number is a number that is evenly divided by only 1 and itself. Write a program to your favorite language to print the first 100 prime numbers.
Sign up free to see the model answer · উত্তর দেখতে বিনামূল্যে সাইন আপ করুন
What is the output of following code?
Sign up free to see the model answer · উত্তর দেখতে বিনামূল্যে সাইন আপ করুন
Answer the following question:
Sign up free to see the model answer · উত্তর দেখতে বিনামূল্যে সাইন আপ করুন
Question text is from the public recruitment exam; answers and explanations are written by ARBS Academy. All past papers · Government IT officer posts guide