Home
Subjects
Computer Science MCQs
Computer Science MCQs
992 multiple choice questions with answers across 24 topics.
Embarking on the vast digital realm, Computer Science is a journey of discovery. It delves into crafting intelligent systems, solving problems through software, and extends to the realm of Artificial Intelligence—teaching computers language understanding and image recognition. Beyond coding, it encompasses database management, utilizing extensive data sets, and ensuring technology serves us optimally.
Computer Scientists contribute to networks, safeguarding information, and enhancing user-friendliness in technology applications, from phone apps to websites. Upholding ethical standards, we prioritize fairness, safety, and privacy. As technology evolves, Computer Science evolves with it, continually enhancing our digital landscape. Join us on this exciting journey into the future of a better, more inclusive digital world!
⚔️
Challenge a friend on Computer Science MCQs
Same MCQs, timed, live leaderboard. Send the link on WhatsApp – no sign-up needed.
Create challenge
A
Database Management System
Correct answer
B
Data Management System
C
Database Manipulation System
D
Data Manipulation System
A
86400 seconds, because the distribution default takes precedence always
B
0 seconds, because the minimum TTL allows revalidation on every request
C
300 seconds, but only when the viewer sends no conditional headers
D
300 seconds, because the origin header overrides the default TTL value
Correct answer
A
It shortens the total retry window, reducing the cost of each failed call
B
It guarantees that a retry will succeed within a bounded number of tries
C
It converts a non-idempotent operation into a safely repeatable one
D
It spreads retries so that clients do not retry in synchronised bursts
Correct answer
A
1 MB per second or 1,000 records per second, whichever limit is reached
Correct answer
B
2 MB per second or 1,000 records per second, whichever limit is reached
C
1 MB per second or 10,000 records per second, whichever limit is reached
D
5 MB per second or 1,000 records per second, whichever limit is reached
A
A latency increase above the threshold set in the routing policy
B
The TTL of the primary record expiring without a refresh from the zone
C
The health check on the primary record failing its configured checks
Correct answer
D
The primary record being deleted from the hosted zone by an operator
A
Each snapshot copies all blocks, but later ones compress more tightly
B
The first copies all used blocks; later ones store only changed blocks
Correct answer
C
Both copy all 100 GB every time, and the service deduplicates afterwards
D
The first is incremental, and a full copy is taken only on the tenth one
A
A NAT gateway inside the private subnet with an elastic IP attached to it
B
A VPC endpoint for the internet that proxies every outbound HTTPS request
C
A NAT gateway in a public subnet, plus a route in the private route table
Correct answer
D
An internet gateway attached to the private subnet's own route table
A
Yes, but only if all three VPCs use non-overlapping CIDR ranges
B
No, unless a shared transit gateway attachment joins all three peers
C
No, because VPC peering is non-transitive and needs a direct peering
Correct answer
D
Yes, because B forwards the traffic when its route tables say so
A
They may be delivered in any order but never more than once at all
B
They are ordered only if a deduplication ID is also supplied for each
C
They are ordered across all groups, since the queue is first-in first-out
D
They are delivered strictly in order, one at a time within that group
Correct answer
A
60 seconds, which reduces empty responses and request charges
B
20 seconds, but this applies only to FIFO queues and not standard ones
C
20 seconds, which reduces empty responses and request charges
Correct answer
D
10 seconds, which reduces empty responses and request charges
A
A 502 error, because Lambda rejects runs longer than 30 seconds
B
A 504 only if reserved concurrency has been configured on the function
C
A 504 timeout, because the integration timeout is capped at 29 seconds
Correct answer
D
A 200 response after 40 seconds, since the gateway waits for the backend
A
15 minutes, after which the invocation is terminated by the service
Correct answer
B
5 minutes, after which the invocation is terminated by the service
C
60 minutes, after which the invocation is terminated by the service
D
15 minutes, though only functions above 1 GB may use the full limit
A
Eventually consistent only, because a GSI is maintained asynchronously
Correct answer
B
Strongly consistent, provided the query targets a single partition key
C
Strongly consistent, but only if the index was created with that setting
D
Either mode, because a GSI is replicated synchronously within the Region
A
5 MiB, with a maximum of 1,000 parts per upload
B
16 MiB, with a maximum of 10,000 parts per upload
C
5 MiB, with a maximum of 10,000 parts per upload
Correct answer
D
1 MiB, with a maximum of 10,000 parts per upload
A
It works until expiry, since the signature alone authorises the request
B
It works only for HEAD requests, because GET needs live credentials
C
It fails only if the object's ETag changes after the URL was generated
D
It fails, because the signing credentials must still be valid when used
Correct answer
A
Denied only if the bucket policy also lists that user in a NotPrincipal element
B
Allowed, because both statements are evaluated and the allow matches first
C
Denied, because an explicit deny anywhere in IAM always overrides any allow
Correct answer
D
Allowed, because identity policies take precedence over resource policies
A
A silent no-op, because the call operator checks for an empty target
B
A segmentation fault, since the internal pointer is null and dereferenced
C
std::bad_function_call is thrown, because no callable target is stored
Correct answer
D
Undefined behaviour, because std::function cannot be empty when called
A
Nothing at all, because a deque never reallocates its element storage blocks
B
References to existing elements, but the iterators remain valid instead
C
Only iterators to the front element, since the rest of the blocks stay
D
All existing iterators, though references to existing elements stay valid
Correct answer
A
The static type Base, because typeid ignores the dynamic type here
Correct answer
B
The dynamic type Derived, since typeid always inspects the vtable
C
A std::bad_typeid exception, since the base class is not polymorphic
D
The most-derived type, but only after a dynamic_cast has been performed
A
Swapping uses move assignment, which the standard requires to be noexcept
B
The old state is replaced only after the copy has been fully constructed
Correct answer
C
The copy constructor cannot throw once the source object has been locked
D
It avoids allocating memory, so no allocation failure can occur at all
A
It returns a default-constructed value through the monadic transform path
B
It throws std::bad_optional_access, unlike operator* which is unchecked
Correct answer
C
It returns a value-initialised object, zero in this case, with no diagnostic
D
It is undefined behaviour, because optional performs no check at all
A
Plain delete is called on the array pointer, which is undefined behaviour
Correct answer
B
delete[] is chosen automatically because the pointer type is an array
C
The control block detects the array and calls the array deleter for you
D
Nothing is freed, because shared_ptr never deletes array allocations at all
A
int, because decltype of a bare name yields its declared type
Correct answer
B
int&, because decltype(auto) gives an lvalue reference
C
int&&, because returning a global binds it to an rvalue reference
D
const int, since the returned object counts as a temporary value
A
It is removed before parsing, so even syntax errors in it are ignored
B
It is compiled and executed at run time only if its condition is true
C
It is discarded and not instantiated, so dependent code there may be invalid
Correct answer
D
It is still instantiated and type-checked, then removed later as a dead branch
A
The defaulted destructor needs Impl complete to invoke the deleter on it
Correct answer
B
unique_ptr can never hold an incomplete type in any context in C++
C
The constructor must see Impl to size the pointer, so the definition is needed
D
The compiler cannot generate a move constructor for an incomplete member
Teacher or blogger? Put this quiz on your website
Free Computer Science MCQs quiz with answers for your school site, academy page or blog. Copy one line of code – works on WordPress and Blogger.
Get the quiz widget