BPSC COMPUTER 25 YEARS PAST PAPERS
BPSC 5
years Past Papers Click
here
چار آپشن میں سے کسی ایک پر کلک کرنے سے جواب سرخ ہو جائے گا۔
جدید کمپیوٹرز میں دستخط شدہ عدد کی نمائندگی کرنے کے لئے مندرجہ ذیل میں سے کون سا استعمال شدہ طریقہ ہے؟
- Excess 127
- 1's complement
- 2's complement
- None of these
اس سوال کو وضاحت کے ساتھ پڑھیں
Explanation
2's complement allows easy addition and subtraction of signed integers without extra logic.
It eliminates the problem of having two zeros, unlike sign-magnitude or 1's complement.
- Range
- Size
- Both A and B
- None of them
اس سوال کو وضاحت کے ساتھ پڑھیں
Explanation
unsigned int cannot store negative numbers, so its range shifts from -2³¹ to 2³¹-1 to 0 to 2³²-1.
The memory size remains the same (4 bytes).
بائنری ڈھیر میں عنصر ڈالنے کی وقت کی پیچیدگی کیا ہے؟
- O(n log n)
- O(1)
- O(log n)
- None of these
اس سوال کو وضاحت کے ساتھ پڑھیں
Explanation
Insertion in a binary heap requires adding the element at the end and then heapifying up to maintain heap property.
The heapify operation takes logarithmic time relative to the number of elements.
گراف میں مختصر ترین راستہ تلاش کرنے کے لیے کون سا الگورتھم استعمال ہوتا ہے؟
- Decision Tree
- Dijkstra's Algorithm
- K-Nearest Neighbors
- None of these
اس سوال کو وضاحت کے ساتھ پڑھیں
Explanation
Dijkstra's Algorithm is used to find the shortest path between nodes in a graph, especially for weighted graphs.It works by iteratively selecting the closest unvisited node and updating the shortest path estimates.
مندرجہ ذیل میں سے کون سا ڈیٹا ڈھانچہ ڈپلیکیٹ عناصر کی اجازت نہیں دیتا ہے؟
- Linked List
- Stack
- Hash Set
- None of these
اس سوال کو وضاحت کے ساتھ پڑھیں
Explanation
Hash Set is a collection that stores unique elements only, automatically ignoring duplicates.
It provides fast lookup and ensures data uniqueness.
It is commonly used in databases and programming applications.
مندرجہ ذیل میں سے کون سا خود توازن بائنری تلاش کا درخت ہے؟
- AVL Tree
- Binary Heap
- Hash Table
- None of these
اس سوال کو وضاحت کے ساتھ پڑھیں
Explanation
AVL Tree is a self-balancing BST where the heights of left and right subtrees differ by at most one, ensuring O(log n) search time.
It automatically rotates nodes during insertion or deletion to maintain balance and efficient operations.
ترجیحی قطار کو نافذ کرنے کے لئے کون سا ڈیٹا ڈھانچہ بہترین ہے؟
- Hash Table
- Heap
- Stack
- None of these
اس سوال کو وضاحت کے ساتھ پڑھیں
Explanation
A heap efficiently supports priority queue operations like insertion and extraction of the highest (or lowest) priority element.
Common types include min-heap and max-heap, which maintain the heap property for fast access to priority elements.
کون سا ڈیٹا ڈھانچہ چابیاں کا استعمال کرتے ہوئے مستقل وقت کی تلاش فراہم کرتا ہے؟
- Hash Table
- Array
- Stack
- None of these
اس سوال کو وضاحت کے ساتھ پڑھیں
Explanation
Hash tables use a hash function to map keys to indices, allowing O(1) average-time lookup.
They are widely used in databases, caching, and associative arrays for fast access to data.
ایک قطار مندرجہ ذیل میں سے کون سے اصول کی پیروی کرتی ہے؟
- FIFO
- LIFO
- SJF
- None of them
اس سوال کو وضاحت کے ساتھ پڑھیں
Explanation
Queue operates on the First In, First Out (FIFO) principle, meaning the first element added is the first to be removed.
Common uses include print job management, task scheduling, and data buffering.
بنیادی طور پر ڈیٹا بیس منطقی اسکیما کو ڈیزائن کرنے کے لئے کون سا آریھ استعمال کیا جاتا ہے؟
- ERD
- Flowchart
- Data flow
- None of these
اس سوال کو وضاحت کے ساتھ پڑھیں
Explanation
ERD (Entity Relationship Diagram) is mainly used to design a database’s logical schema.
It shows entities, attributes, and relationships between data elements.