Aspire's Library

A Place for Latest Exam wise Questions, Videos, Previous Year Papers,
Study Stuff for MCA Examinations

WB JECA MCA Previous Year Questions (PYQs)

WB JECA MCA Computer PYQ


WB JECA MCA PYQ
Find out the wrong statement based on the characteristics of AVL tree data structure.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

 AVL trees guarantee O(log n) search time, not O(n).


WB JECA MCA PYQ
Example of non-linear data structure is __________.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Graphs and trees are non-linear data structures, while linked-list, queue, and stack are linear.


WB JECA MCA PYQ
Bubble sort algorithm has a worst-case time complexity of __________.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Graphs and trees are non-linear data structures, while linked-list, queue, and stack are linear.


WB JECA MCA PYQ
Insertion sort algorithm has a best-case time complexity of __________.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Insertion sort runs in O(n) time when the array is already sorted (best case).


WB JECA MCA PYQ
In machine learning, VC dimension is used to measure the capacity of a set of functions.  
VC means __________.  






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

VC dimension stands for Vapnik–Chervonenkis dimension, a measure of model capacity/complexity.


WB JECA MCA PYQ
Artificial Neural networks are __________ algorithms.  






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Artificial Neural Networks (ANNs) are computational algorithms inspired by biological neural networks.


WB JECA MCA PYQ
One-class SVM is __________ algorithm.  





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

One-class SVM is mainly used for anomaly/outlier detection, which falls under unsupervised learning.


WB JECA MCA PYQ
Time complexity of K-Means clustering is __________.  






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

For K-Means, the time complexity per iteration is O(kN), where k = number of clusters and N = number of data points.


WB JECA MCA PYQ
__________ algorithm is used to find out the shortest path between two points in a connected weighted graph.  






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Kruskal’s algorithm (and Prim’s) are used in shortest path/minimum spanning tree problems.


WB JECA MCA PYQ
Forward–backward algorithm is used in case of HMM to compute __________ of all hidden state variables.  






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

The forward–backward algorithm in Hidden Markov Models (HMM) is used to compute posterior marginals over hidden states.


WB JECA MCA PYQ
HMM is a specific instance of CRF which is known as __________.  






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Hidden Markov Model (HMM) is a probabilistic model and can be seen as a special case of Conditional Random Fields (CRF).


WB JECA MCA PYQ
In FP-Growth Algorithm, FP means __________





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

In FP-Growth, FP stands for Frequent Pattern, used in association rule mining.


WB JECA MCA PYQ
In software engineering, what is the full form for PERT chart?  






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Program Evaluation and Review Technique


WB JECA MCA PYQ
In software engineering, the testing performed by development team is known as ______.  






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Alpha testing is performed internally by the development team before releasing the software for beta testing.


WB JECA MCA PYQ
In software engineering, a prototyping model can be used when __________.  





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Technical solutions are unclear to the development team


WB JECA MCA PYQ
60.In classical waterfall model, which phase comes before the design phase?  






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Requirements analysis and specification


WB JECA MCA PYQ
In software engineering, which of the following is not a type of cohesion?






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Projection” is not a type of cohesion.


WB JECA MCA PYQ
In software engineering, which of the following is not a type of coupling?






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Coupling types are Data, Stamp, Control, Common, Content.
“Connection” is not a coupling type.


WB JECA MCA PYQ
Choose the correct option as the activities of the first quadrant of Spiral model.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Determine objectives, alternatives and constraints


WB JECA MCA PYQ
 Choose the appropriate black-box testing technique in software engineering.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Boundary Value Analysis (BVA) is a black-box testing technique used to check inputs at their boundary values.


WB JECA MCA PYQ
In User Datagram packet format, the size of the header is ________.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

The UDP header is 8 bytes (64 bits) long — containing source port, destination port, length, and checksum.


WB JECA MCA PYQ
Transmission Control Protocol (TCP) offers __________ service in which data can flow in both directions at the same time.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

TCP provides a full-duplex service — meaning data can flow simultaneously in both directions.


WB JECA MCA PYQ
Example of a two-layer switch is ____________.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

A bridge operates at Layer 2 (Data Link Layer) and is considered a two-layer switch.


WB JECA MCA PYQ
A ____________ routing table contains information entered manually.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

A static routing table is manually configured by the administrator.


WB JECA MCA PYQ
BOOTP is ____________ layer protocol.
(A) application
(B) physical
(C) network
(D) datalink





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

BOOTP (Bootstrap Protocol) works at the application layer of the OSI model.


WB JECA MCA PYQ
ICMP always reports error messages to the original ____________.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

ICMP error messages are always sent back to the source of the packet.


WB JECA MCA PYQ
The ____________ program uses ICMP messages and TTL field in IP packet to find route.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

traceroute uses ICMP Echo and TTL fields to determine the route to a destination.


WB JECA MCA PYQ
SNMP is ____________ level protocol.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

SNMP (Simple Network Management Protocol) is an application layer protocol.


WB JECA MCA PYQ
Which key can be derived directly from a Super Key?






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

A Candidate Key is derived from a Super Key, and then one candidate key is chosen as the Primary Key.


WB JECA MCA PYQ
Relational Algebra is ____________ query language.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Relational Algebra is a procedural query language because it specifies the operations to obtain the result.


WB JECA MCA PYQ
 In case of union compatibility, ____________






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

For union compatibility, two relations must have the same set of attributes and domains.


WB JECA MCA PYQ
Which option cannot be used with “ALTER table” command in SQL ?






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

ALTER TABLE can ADD, MODIFY, and DROP columns, but DELETE is a DML operation, not part of ALTER.


WB JECA MCA PYQ
Third normal form (3NF) removes ____________ from a relation.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

3NF eliminates transitive dependencies.


WB JECA MCA PYQ
Which option is not a step for query processing ?






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Metadata organization is not a query processing step.


WB JECA MCA PYQ
Which of the following option is not a transaction state ?






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Transaction states are Active, Partially committed, Failed, Aborted, Terminated. There is no "Updated" state.


WB JECA MCA PYQ
Which of the following option does not have any partial functional dependencies ?






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

2NF removes partial dependency.


WB JECA MCA PYQ
What is the output of the following code snippet?  
#include <stdio.h>
main() {
int x = 65, *p = &x;
void *q = p;
char *r = q;
printf("%c", *r);
}

(A) $A$  
(B) $Z$  
(C) $65$  
(D) None of the above  





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Step 1: Initialization

$x = 65$
In ASCII, $65 \equiv A$

Step 2: Pointer flow
$p = \&x \;\; \rightarrow$ pointer to integer
$q = p \;\; \rightarrow$ void pointer
$r = q \;\; \rightarrow$ typecast to char pointer

Step 3: Dereferencing
Since r is char*, it reads 1 byte.
The value stored = $65$

Step 4: Printing
printf("%c", *r); prints character with ASCII $65$.
Hence, the output is:

$\; \boxed{A} \;$

Correct Answer: (A) 


WB JECA MCA PYQ
ROM is a 
(A) Combinational Circuit 
(B) Static Circuit
(C) Sequential Circuit 
(D) Magnetic Circuit





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

- ROM (Read Only Memory) stores fixed data permanently.

- Its output depends only on the given input address.
- No clock or feedback is required, so it is not sequential.
- Hence, ROM is a Combinational Circuit.

Correct Answer: (A) Combinational Circuit

WB JECA MCA PYQ
Each stage in pipelining should be completed within _________cycles.
(A) 1 
(b) 2
(C) 3 
(D) 4





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

  • In pipelining, the CPU instruction is divided into stages (Fetch, Decode, Execute, etc.).
  • To maximize throughput, each stage must complete within 1 clock cycle.
  • This ensures that new instructions can enter the pipeline without delay.

Correct Answer: (A) 1

WB JECA MCA PYQ
Relational calculus is a 
(A) Procedural language 
(B) Non-procedural language
(C) Data definition language 
(D) High-level language





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution


  • Relational Algebra is procedural (it specifies how to obtain the result).
  • Relational Calculus is non-procedural (it specifies what to obtain, not how).
Therefore, Relational Calculus is a Non-procedural language.

Correct Answer: (B) Non-procedural language

WB JECA MCA PYQ
How many parameters does a default constructor require ? 
(A) 1
(B) 2 
(C) 0
(D) 3





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

  • A default constructor in C++ is a constructor that takes no arguments.
  • It is invoked automatically when an object is created without passing parameters.
Hence, it requires 0 parameters.

Correct Answer: (C) 0

WB JECA MCA PYQ
An artificially intelligent car decreases its speed based on its distance from the car in front of it. Which method is used?
  • (A) Naive Bayes
  • (B) Decision Tree
  • (C) Linear Regression
  • (D) Logistic Regression





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

  • The car’s speed is a continuous variable that depends on the distance from the car ahead.
  • To model this relation, we need a method for predicting a continuous outcome.
Linear Regression is used because it maps distance (input) to speed (output).

Correct Answer: (C) Linear Regression

WB JECA MCA PYQ
The keyword friend does not appear in
(A) the class allowing access to another class.
(B) the class desiring access to another class.
(C) the private section of a class.
(D) the public section of a class.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

  • The friend keyword is used inside a class definition to allow another class or function to access its private/protected members.
  • It appears in the class granting access (not the one desiring access).
  • It can be declared in either public or private section of that class.
Hence, it does not appear in the class desiring access.

Correct Answer: (B) the class desiring access to another class

WB JECA MCA PYQ
What is the maximum number of level-2 DFD possible if the number of processes in level-1 DFD is n ?
(A) $\frac{n}{2}$
(B) 2
(C) $n^2$
(D) n





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

  • In a Data Flow Diagram (DFD), each process in level-1 can be decomposed further into its own level-2 diagram.
Therefore, if there are n processes at level-1, then maximum possible level-2 DFDs = n.

Correct Answer: (D) $n$

WB JECA MCA PYQ
The small extremely fast RAM's are termed as ______
(A) Heap
(B) Accumulators
(C) Stack
(D) Cache





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

  • Heap → Memory area for dynamic allocation.
  • Accumulator → Register in CPU for intermediate results.
  • Stack → Memory area used for function calls and local variables.
  • Cache → Small, high-speed RAM located close to the CPU, used to store frequently accessed data.
Hence, the correct answer is Cache.

Correct Answer: (D) Cache

WB JECA MCA PYQ
A computer with a 32 bit wide data bus uses 4k × 8 static RAM memory chips. The smallest memory this computer is





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Each RAM chip = $4k \times 8 = 32k$ bits = 4 KB.
Bus width = 32 bits, each chip = 8 bits → need 4 chips in parallel.
Total memory = $4 \times 4$ KB = 16 KB.
Answer = (B) 16 kb

WB JECA MCA PYQ
K-means clustering method is an example of which type of clustering method?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

K-means clustering is a partitioning method because it divides the dataset into k clusters based on distance.
Answer = (D) Partitioning

WB JECA MCA PYQ
The store and forward mechanism is used in





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

In message switching, the entire message is stored at intermediate nodes and then forwarded → store and forward.
Answer = (B) Message Switching

WB JECA MCA PYQ
What is the output of the following C-program?
#include
int main() { 
const int a=10; 
printf("%d", +a); 
return 0; 
}





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

The constant a=10. Unary +a does not increment, it only returns the same value.
So, output = 10.
Answer = (B) 10

WB JECA MCA PYQ
How can you display a list of all files including the hidden files?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

In Linux/Unix, hidden files are shown using ls -a.
Answer = (C) ls -a

WB JECA MCA PYQ
Which C keyword is used to extend the visibility of variables?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

The extern keyword is used in C to extend variable visibility across multiple files.
Answer (C) extern

WB JECA MCA PYQ
Which of the following should not have transitive dependency?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution:
- 3NF (Third Normal Form) removes transitive dependency.
- Hence, it should not have transitive dependency.
Answer = (C) Third normal form

WB JECA MCA PYQ
Regression is a type of:





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution:
- Regression uses labeled data to predict continuous values.
- It belongs to Supervised Learning.
Answer = (A) Supervised learning

WB JECA MCA PYQ
What is the output of the following C-program?\n#include\n#define CUBE(x) (x*x*x)\nint main() { int a, b=3; a = CUBE(b++); printf("%d, %d\n", a, b); return 0; }





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution:
- Macro expansion: CUBE(b++) → (b++ * b++ * b++).
- This causes multiple side effects → undefined behavior.
- Most compilers treat this as error/undefined.
Answer = (D) Error

WB JECA MCA PYQ
The _____ is an asymmetric key cryptographic algorithm.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution:
- RSA is an asymmetric key cryptographic algorithm.
- Others are not asymmetric cryptography.
Answer = (A) RSA

WB JECA MCA PYQ
What is the purpose of the confusion matrix in machine learning?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution:
- Confusion matrix is used in classification tasks.
- It compares predicted vs actual labels (TP, FP, TN, FN).
Answer = (C) To evaluate the performance of a classification model

WB JECA MCA PYQ
In DMA transfers, the required signals and addresses are given by the ____.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: In Direct Memory Access (DMA), the DMA controller takes over bus control to put addresses/control signals on the bus, freeing the CPU.
Answer: (C) DMA controllers

WB JECA MCA PYQ
What is the output of following C code? int main(){ int x=2, y=1; x *= x + y; printf("%d", x); }





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: x *= x + y means x = x * (x + y)2 * (2 + 1) = 6.
Answer: (D) 6

WB JECA MCA PYQ
Which among the following can’t be used for polymorphism?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Static member functions cannot be virtual; hence they don’t participate in runtime polymorphism. Overloading (functions/operators/constructors) supports polymorphism.
Answer: (A) Static member functions

WB JECA MCA PYQ
If there are 32 segments each of size 1K bytes, then the logical address should have





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: 32 segments ⇒ segment bits = $\log_2 32 = 5$. Size = 1 KB ⇒ offset bits = $\log_2 1024 = 10$.
Total address bits $= 5 + 10 = \boxed{15}$.
Answer: (D) 15 bits

WB JECA MCA PYQ
In software engineering the tester does not know the internal designs of the software application in case of _____ testing.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Black-box testing validates functionality without knowledge of internal code/design.
Answer: (B) Black Box

WB JECA MCA PYQ
What is the output of the following code snippet? #include int main(){ int x; x = 5 > 8 ? 10 : 1 != 2 < 5 ? 20 : 30; printf("%d", x); return 0; }





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: 5>8 is false ⇒ evaluate 1 != 2 < 5 ? 20 : 30.
Relational before != : 2<5 ⇒ 1. Then 1 != 1 ⇒ false ⇒ choose 30.
Answer: (D) 30

WB JECA MCA PYQ
_____ is a measure of the degree of interdependence between modules.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Coupling measures interdependence between modules; cohesion measures internal relatedness within a module.
Answer: (B) Coupling

WB JECA MCA PYQ
The permission -rwx r-- r-- represented in octal expression will be





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Owner rwx = 7, group r-- = 4, others r-- = 4 ⇒ 744.
Answer: (B) 744

WB JECA MCA PYQ
What will be the output of the C code? #include int main(){ int a=1; if(a--) printf("True"); if(a++) printf("False"); }





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: First if(a--) uses 1 (true) then decrements to 0 ⇒ prints "True".
Second if(a++) tests 0 (false) then increments to 1 ⇒ no print.
Answer: (A) True

WB JECA MCA PYQ
Which command changes a file's group owner?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: The Unix command to change a file's group is chgrp (change group).
Answer: (D) chgrp

WB JECA MCA PYQ
Which of the following is an example of a classification problem?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Classification predicts categories. Customer churn = Yes/No ⇒ classification.
Answer: (C) Predicting whether a customer will churn or not

WB JECA MCA PYQ
What is the output of the C-program? int main(){ int i=0; int x=i++; int y=++i; printf("%d %d", x,y); }





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: The snippet shown misses a declaration of y (outside initialization), so it will not compile. Hence, it gives a compilation error.
Answer: (D) compile error

WB JECA MCA PYQ
What is the difference between supervised and unsupervised learning?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Supervised = labelled data, Unsupervised = unlabelled data.
Answer: (A) Supervised learning requires labelled data while unsupervised learning does not.

WB JECA MCA PYQ
If a file has read and write permission for the owner, then the octal representation of the permissions will be:





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Read=4, Write=2 ⇒ total = 6.
Answer: (C) 6

WB JECA MCA PYQ
In an ER diagram, an entity set is represented by a





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Entity sets are rectangles; Attributes = ellipses; Relationships = diamonds.
Answer: (A) Rectangle

WB JECA MCA PYQ
What is the output of the C-program? int main(){ int i=0; while(i=0) printf("True"); printf("False"); }





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: while(i=0) assigns 0 ⇒ condition false ⇒ loop not executed. Prints "False".
Answer: (C) False

WB JECA MCA PYQ
Identify the incorrect constructor type:





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: In C++, there is no concept of Friend Constructor. Others exist.
Answer: (A) Friend Constructor

WB JECA MCA PYQ
_____ specification is also known as the SRS document.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: SRS (Software Requirement Specification) = Black-box specification (focuses on external behavior).
Answer: (C) Black-box

WB JECA MCA PYQ
What is the output of the following code snippet? int main(){ int i,k=5; if(i=k){ printf("YES"); } else { printf("NO"); } }





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: if(i=k) assigns 5 to i ⇒ condition true ⇒ executes if-block ⇒ prints "YES".
Answer: (B) YES

WB JECA MCA PYQ
Which of the following is/are not shared by threads?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Threads share code, data, and OS resources, but each thread has its own stack and program counter.
Answer: (C) Both program counter and stack

WB JECA MCA PYQ
Given an unsorted array where each element is at most k distance from its position in a sorted array. Which sorting algorithm can be easily modified for this and what is its time complexity?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: A k-sorted array can be efficiently sorted using a min-heap of size k, yielding O(n log k) time.
Answer: (B) Heap Sort with O(n log k)

WB JECA MCA PYQ
Which one of the following is a synchronization tool?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Semaphore is used for process synchronization, unlike pipe/socket/thread.
Answer: (C) Semaphore

WB JECA MCA PYQ
When a process is in a "Blocked" state waiting for some I/O service, once completed it goes to the ____.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: A blocked process (waiting for I/O) goes to the Ready state after I/O is completed.
Answer: (D) Ready state

WB JECA MCA PYQ
A process is thrashing if ____.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Thrashing occurs when the CPU spends most of its time handling page faults rather than executing instructions.
Answer: (B) it spends more time in paging, rather than in execution

WB JECA MCA PYQ
_____ is not among the eight principles followed by the Software Code of Ethics and Professional Practice.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: The eight principles include: Public, Client, Product, Judgment, Management, Profession, Colleagues, Self. Environment is not one of them.
Answer: (B) ENVIRONMENT

WB JECA MCA PYQ
Making class members inaccessible to nonmember functions is an example of:





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Restricting access to internal details of a class is data hiding (encapsulation).
Answer: (B) data hiding

WB JECA MCA PYQ
In a relational database, what does the term "ACID" stand for?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: ACID properties are Atomicity, Consistency, Isolation, Durability. Option (A) is closest (Integrity ~ Isolation).
Answer: (A) Atomicity, Consistency, Integrity, Durability

WB JECA MCA PYQ
Which of the given statement is the correct recurrence for the worst case of Binary Search?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Binary search recurrence is T(n) = T(n/2) + O(1). Base case T(1)=O(1).
Answer: (C) T(n) = T(n/2) + O(1)

WB JECA MCA PYQ
Which of the following statements about primary key in a database table is true?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: A table can have only one primary key, it cannot contain NULLs. Its main property: uniquely identifies each record.
Answer: (B) A primary key uniquely identifies each record in a table

WB JECA MCA PYQ
Which of the following data structure is required to convert an arithmetic expression in infix form to its equivalent postfix form ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Infix→postfix conversion (e.g., Shunting-yard) uses a stack to manage operators and parentheses.
Answer: (D) Stack

WB JECA MCA PYQ
Which is the correct statement about operator overloading ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Overloading changes operator meaning for user types, but its precedence and associativity never change.
Answer: (D)

WB JECA MCA PYQ
Numbers 7, 5, 1, 8, 3, 6, 0, 9, 4, 2 are inserted in that order into an initially empty binary search tree. The tree uses usual ordering. What is the in-order traversal sequence?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: In-order traversal of a BST gives the sorted order of keys ⇒ 0 to 9 ascending.
Answer: (C) 0, 1, 2, 3, 4, 5, 6, 7, 8, 9

WB JECA MCA PYQ
Which of the following is popular for applications such as storage of log files in a DBMS since it offers the best write performance ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: RAID 0 (striping) provides maximum write throughput (no redundancy), often used for logs/temp data.
Answer: (A) RAID level 0

WB JECA MCA PYQ
Which of the following statement is correct ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: For a BST, only in-order traversal yields the keys in sorted order.
Answer: (B)

WB JECA MCA PYQ
Which one of the following is deadlock avoidance algorithm ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Banker's algorithm checks for safe state to avoid deadlocks.
Answer: (B)

WB JECA MCA PYQ
Which command is used to set the three permissions for all the three categories of users of a file ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: chmod sets read/write/execute bits for user, group, others (e.g., chmod 744 file).
Answer: (C) chmod

WB JECA MCA PYQ
Which command is used for printing the current working directory ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: The Unix command to print the current directory is pwd.
Answer: (D) pwd

WB JECA MCA PYQ
When several processes access the same data concurrently and the outcome depends on the particular order in which the access takes place is called ________.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Order-dependent outcomes from concurrent access is a classic race condition.
Answer: (A) Race condition

WB JECA MCA PYQ
Baud means





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Baud = number of signal changes per second, not bits/bytes directly.
Answer: (C)

WB JECA MCA PYQ
Which option will be used with sort command to start sorting after the n-th column of the (m+1)th field ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: The Unix sort option to specify starting column is +m -n.
Answer: (B)

WB JECA MCA PYQ
Which layer of the OSI model is responsible for routing and forwarding packets ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Routing and forwarding are functions of the Network Layer (Layer 3).
Answer: (A)

WB JECA MCA PYQ
Which command is used for displaying the beginning of a file in Unix ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: The head command displays first lines of a file.
Answer: (D)

WB JECA MCA PYQ
Three CPU-intensive processes (10, 20, 30 units) arrive at 0,2,6 respectively. Using shortest remaining time first scheduling, how many context switches are needed (excluding t=0 and end)?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: SRTF will preempt at arrivals (P1→P2 at t=2, P2→P3 at t=6). Thus 2 context switches occur.
Answer: (B) 2

WB JECA MCA PYQ
What is the result of postfix expression ab*c+d+ where a=2, b=2, c=3, d=4 ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Postfix: a*b*c + d + ⇒ 2*2*3 + 4 = 12+4 = 16 (check carefully). Actually: ab* c + d + → (a*b)+c+d.
2*2+3+4=11 (typo). But correct reading: (a*b*c)+d= (2*2*3)+4=16. Options given: 16 present.
Answer: (A) 16

WB JECA MCA PYQ
Which one of the following does not have a Net ID and Host ID ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Class D addresses (224.0.0.0–239.255.255.255) are multicast, not divided into NetID/HostID.
Answer: (D)

WB JECA MCA PYQ
Which command is used to extract specific columns from the file ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: The cut command extracts columns/fields from text files.
Answer: (B)

WB JECA MCA PYQ
In the OSI model, encryption and decryption are functions of the ____.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: The Presentation Layer handles encryption/decryption and data translation.
Answer: (C)

WB JECA MCA PYQ
Which of the following is not a communication command ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: grep is for searching text, not communication.
Answer: (D)

WB JECA MCA PYQ
A deadlock avoidance algorithm dynamically examines the ____ to ensure circular wait never exists.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Deadlock avoidance (e.g., Banker's) examines the resource allocation state.
Answer: (D)

WB JECA MCA PYQ
A Port address in TCP/IP is ____ bits long.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: TCP/UDP port numbers are 16-bit integers.
Answer: (C) 16

WB JECA MCA PYQ
Worst case time complexity of inserting into an empty linear linked list, if list must remain sorted?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: To keep list sorted, insertion needs traversal O(n).
Answer: (A) Θ(n)

WB JECA MCA PYQ
In IPv4 network ID and host ID in Class A is:





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Class A: 1 byte netID, 3 bytes hostID ⇒ 8+24 bits.
Answer: (A)

WB JECA MCA PYQ
What is the worst case complexity of inserting a node in doubly linked list ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Insertion in DLL is O(1) (given pointer to location).
Answer: (D)

WB JECA MCA PYQ
Virtual memory is normally implemented by ____.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Virtual memory is usually implemented using demand paging.
Answer: (A)

WB JECA MCA PYQ
Which sorting algorithm is most efficient if elements are already in sorted order ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Insertion sort runs in O(n) when input is already sorted.
Answer: (C)

WB JECA MCA PYQ
____ server is used to create a secure tunnel connection.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Secure tunnel is provided by a VPN server.
Answer: (B)

WB JECA MCA PYQ
What is the prefix of expression A-B/(C*D^E) ?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Infix: A - B/(C*D^E). Precedence: ^ > * > /. Prefix = - A / B * C ^ D E.
Answer: (A)

WB JECA MCA PYQ
Hamming code is used for ____.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2024 PYQ

Solution

Solution: Hamming code detects and corrects single-bit errors ⇒ both detection & correction.
Answer: (D)

WB JECA MCA PYQ
What is the output of the following program ? 
#include void main ( ) 
 { 
 int a = 40; float b; 
 b = ++a; 
 printf(“%d, %f ”, a, ++b); 
 }





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution


WB JECA MCA PYQ

What is the output of the following C program?

#include <stdio.h>
void main(){
  int a = -7;
  float b;
  b = a++;
  printf("%d, %f ", a, ++b);
}





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: The statement b = a++; assigns the current value of a (−7) to b and then increments a to −6. Later, ++b increments b from −7 to −6 before printing. $$ a = -6,\quad b = -6.000000 $$

WB JECA MCA PYQ

What is the output?

#include <stdio.h>
void main(){
  int i = -1;
  printf("sizeof(i) = %d", sizeof(i));
}





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: The operator sizeof gives the size of the type in bytes, not the value. On most 32-bit and 64-bit systems, sizeof(int) is 4. $$ \text{Output: } \texttt{sizeof(i) = 4} $$

WB JECA MCA PYQ

What is the output?

#include <stdio.h>
void main(){
  int x = -1, y = 1, z = 0;
  if(x && y++ && z)
    ++x, y++, --z;
  printf("%d, %d, %d", x++, y++, z++);
}





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: In the condition x && y++ && z, since z = 0, the logical AND short-circuits and the body of the if is not executed. However, y++ is evaluated before the short-circuit, so y becomes 2. Values before printing: $$ x = -1,\ y = 2,\ z = 0 $$ So the program prints: $$ (-1,\ 2,\ 0) $$

WB JECA MCA PYQ

What is the output?

#include <stdio.h>
enum colors{RED, BROWN, ORANGE};
void main(){
  printf("%ld..%f..%d", RED, BROWN, ORANGE);
}





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: The format specifiers do not match the data types (%f is used for int). This causes undefined behavior. The program may compile, but the output is not reliable. Correct choice: None of these.

WB JECA MCA PYQ

What is the output?

#include <stdio.h>
void main(){
  char M = 'M';
  printf("%d, %c", M, M);
}





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: The character 'M' has an ASCII value of 77. So printing with %d shows 77, and %c shows M. $$ \text{Output: } 77,\ M $$

WB JECA MCA PYQ

What is the output?

#include <stdio.h>
void main(){
  int i = -9;
  printf("%d %d %d", i++, ++i, ++i);
}





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Ek hi expression me variable i par multiple modifications → C standard me undefined behavior.
Isliye koi fixed output/compile error guarantee nahi. Sahi option: None of these.

WB JECA MCA PYQ

What is the output?

#include <stdio.h>
void main(){
  int **ptr;
  int temp = 65;
  ptr[0] = &temp;
  printf("%d", ptr[0][0]);
}





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: The pointer ptr is uninitialized, so it does not point to valid memory. When the code tries to access ptr[0], it attempts to dereference an invalid location. This leads to undefined behavior, and in most cases results in a segmentation fault.

WB JECA MCA PYQ

What is the output?

#include <stdio.h>
#include <stdlib.h>
void main(){
  int *ptr;
  ptr = (int*) calloc(3, sizeof(int));
  ptr[2] = 30;
  printf("%d", *ptr);
  free(ptr);
}





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: The function calloc initializes all allocated memory blocks with zero. So ptr[0] is initialized to 0. The statement *ptr is equivalent to ptr[0]. $$ \text{Output: } 0 $$

WB JECA MCA PYQ

__________ interrupt may happen due to power failure.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Power failure ⇒ Hardware interrupt.

WB JECA MCA PYQ

11. Address of the next instruction to be executed is specified by ______________.

(A) MBR   (B) MAR   (C) PSW   (D) PC






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: The Program Counter (PC) holds the address of the next instruction to be fetched and executed.

WB JECA MCA PYQ

12. Auxiliary memory is also known as ______________ memory.

(A) Primary   (B) Secondary   (C) Binary   (D) Quad






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: Auxiliary storage refers to secondary memory (e.g., HDD, SSD, tapes) used for non-volatile, large-capacity storage.

WB JECA MCA PYQ

13. BIOS means ______________.

(A) basic input/output system   (B) best input/output system   (C) basic input system   (D) basic output system






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: BIOS stands for Basic Input/Output System, firmware that initializes hardware and starts the boot process.

WB JECA MCA PYQ

14. _________ is the most appropriate scheduling in case of a time-shared operating system.

(A) FCFS   (B) RR   (C) SJF   (D) SRTF






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: Time-sharing systems aim for responsiveness and fairness, which is best provided by Round Robin (RR) using time quanta.

WB JECA MCA PYQ

15. If only one process can be able to access a particular resource at a time, then it is known as ______________.

(A) Mutual execution   (B) Mutual exclusion   (C) Multiple execution   (D) Multiple exclusion






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: Allowing only one process to access a resource at a time is called mutual exclusion (mutex).

WB JECA MCA PYQ

16. Resource allocation graph is used to represent ______________.

(A) deadlock   (B) virtual memory   (C) main memory   (D) scheduling






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: Resource Allocation Graph (RAG) models processes and resources; cycles in certain cases indicate deadlock.

WB JECA MCA PYQ

17. Banker’s algorithm for resource allocation deals with ______________.

(A) mutual exclusion   (B) mutual inclusion   (C) deadlock recovery   (D) deadlock avoidance






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: Banker’s algorithm is a deadlock avoidance algorithm ensuring the system stays in a safe state.

WB JECA MCA PYQ

18. Page fault means ______________.

(A) required page is available in main memory   (B) required page is not available in main memory   (C) segment number   (D) reduce page I/O






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: A page fault occurs when the referenced page is not present in main memory, forcing a page-in from secondary storage.

WB JECA MCA PYQ

19. ___________ is a technique to move a process from main memory to secondary memory.

(A) Deadlock   (B) Synchronization   (C) Caching   (D) Swapping






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: Swapping transfers processes between main memory and secondary storage to manage memory pressure.

WB JECA MCA PYQ

20. Demand paging is considered as ______________.

(A) fetching a page when not needed   (B) switching between two processes   (C) fetching a page only when needed   (D) switching between two threads






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: In demand paging, a page is loaded into memory only when it is actually referenced.

WB JECA MCA PYQ

21. Thrashing means a condition having ______________.

(A) minimum paging   (B) optimized paging   (C) synchronized paging   (D) excessive paging






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: Thrashing occurs when the system spends most time paging due to insufficient frames, causing excessive paging and poor performance.

WB JECA MCA PYQ

22. A counting semaphore is initialized to 15. Then, 4 wait operations and 2 signal operations are completed on this semaphore. The resulting value of the semaphore is ____________.

(A) 11   (B) 13   (C) 17   (D) 19






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: Each wait (P) decrements; each signal (V) increments. Initial: 15 → after 4 waits: 11 → after 2 signals: 13. $$ 15 - 4 + 2 = 13 $$

WB JECA MCA PYQ

23. What do you mean by fork()? Choose the correct option.

(A) Starvation   (B) Creation of new task   (C) Demand paging   (D) Semaphore






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: fork() creates a new process (child) as a copy of the calling process.

WB JECA MCA PYQ

24. In file management, FAT means ______________.

(A) Feature Access Table   (B) File Access Table   (C) Fault Allocation Table   (D) File Allocation Table






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Explanation: FAT stands for File Allocation Table, a file system layout used to map files to disk clusters.

WB JECA MCA PYQ
25.What is the output of the following program ?  include <iostream>  using namespace std;  int addition (int a, int b)  {   return a+b;  }  double addition (double a, double b)  {   return a+b;  }  int main ()  {   cout<< addition (35,20) << “;”;   cout<< addition (34.1,12.7);   return 0;  } 





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

The given program defines two overloaded functions `addition`:  
1. `int addition(int a, int b)` → returns integer sum  
2. `double addition(double a, double b)` → returns double sum  

In `main()`:
- `addition(35,20)` calls the integer version → 35 + 20 = 55  
- `addition(34.1,12.7)` calls the double version → 34.1 + 12.7 = 46.8  

Therefore, the output is:  
55;46.8


WB JECA MCA PYQ
26.What is the output of the following program ?  #include <iostream>  using namespace std;  template <class C1, class C2>  bool is_equal (C1 var1, C2 var2)  {   return (var1 = = var2);  }  int main ()  {   if (is_equal(10,10.0))    cout<< “Equal”;   else    cout<< “Not equal”;   return 0;  } 





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

The function `is_equal` is a template that compares two variables of possibly different types.  
In `main()`, we call `is_equal(10, 10.0)`.  

- `10` is an integer (int).  
- `10.0` is a double.  
C++ allows implicit type conversion during comparison.  
So, `10 == 10.0` evaluates to `true`.  

Therefore, the condition in the `if` statement is true, and the output will be:  

Equal


WB JECA MCA PYQ
26.What is the output of the following program ?

#include <iostream>
using namespace std;

int main() 
{
    int var = 0;
    while (var < 10) 
    {
        cout << var << " ";
        var++;
    }
    cout << var;
    return 0;
}






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Output:
0 1 2 3 4 5 6 7 8 9 10

Explanation:

  • The variable var starts at 0.

  • The while (var < 10) loop prints 0 1 2 3 4 5 6 7 8 9 with spaces.

  • When var reaches 10, the loop stops.

  • After the loop, cout << var; prints 10.

    Final output:

    0 1 2 3 4 5 6 7 8 9 10


WB JECA MCA PYQ
What is the output of the following program ?
#include <iostream>
using namespace std;
struct demo
{
    int var;
};
int main()
{
    demo str;
    demo *ptr;

    str.var = 100;
    ptr = &str;
    cout << ptr->var;
    return 0;
}






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Output:
100
Explanation:

str.var = 100; assigns 100 to the structure variable.

ptr = &str; makes the pointer point to str.

ptr->var accesses the member var of structure str via pointer.

Hence it prints 100.


WB JECA MCA PYQ
29.What is the output of the following program ?
#include <iostream>
using namespace std;
int main ()
{
    int c1 = 10;
    int c2 = 20;
    {
        int c1;
        c1 = 50;
        c2 = 50;
        cout << "c1= " << c1 << ", c2=" << c2;
    }
    cout << ", c1= " << c1 << ", c2=" << c2;
    return 0;
}






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

  • Output:
    c1= 50, c2=50, c1= 10, c2=50
    Explanation:

    Outer c1 = 10, c2 = 20.

    Inside the inner block, a new local c1 is declared (shadowing outer c1).

    Inner c1 = 50, and c2 (outer one) is updated to 50.

    First cout prints → c1= 50, c2=50.

    After the block ends, inner c1 is destroyed. Outer c1 remains 10, while outer c2 is 50.

    Second cout prints → , c1= 10, c2=50.

    ? Final output: c1= 50, c2=50, c1= 10, c2=50.


WB JECA MCA PYQ
30.What is the output of the following program ?
#include <iostream>
using namespace std;

class Demo {
public:
    static int count;
    Demo() { count++; }
};

int Demo::count = 0;

int main() {
    Demo var1;
    Demo var2[5];
    cout << var1.count;
    return 0;
}






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

  • Explanation:

    • int Demo::count = 0; initializes the static variable count to 0.

    • Demo var1; → constructor is called once → count = 1.

    • Demo var2[5]; → constructor is called 5 times (for each element in the array) → count = 6.

    • Since count is static, it is shared among all objects.

    • Finally, cout << var1.count; prints 6.

    ? Correct answer: (A) 6


WB JECA MCA PYQ
31.What is the output of the following program ?
#include <iostream>
using namespace std;

void print();
int main()
{
    int var = 0;
    var = print();
    cout << var;
    return 0;
}

void print()
{
    cout << "Hi";
}






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

  • Explanation:

    • print() is declared as void print().

    • In main(), the statement var = print(); tries to assign the return value of print() to an int variable.

    • But since print() has no return value (void), this causes a compile-time error.

    Hence, the program does not compile.


WB JECA MCA PYQ
32.What is the output of the following program ?
#include <iostream>
using namespace std;

int main()
{
    int var = 2;
    do
    {
        cout << var;
    } while (var--);
    return 0;
}






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

  • Explanation:

    • Initially var = 2.

    • First iteration: prints 2, then var-- makes var = 1.

    • Second iteration: prints 1, then var-- makes var = 0.

    • Third iteration: prints 0, then var-- makes var = -1. Condition fails and loop exits.

    So output is:


WB JECA MCA PYQ
33.In shell script, which command is used to create a new directory ? 





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

  • mkdir is the command to create a new directory in Unix/Linux.


WB JECA MCA PYQ
34.In shell script, which command is used to copy a file?






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

  • cp is used to copy files or directories in Unix/Linux.


WB JECA MCA PYQ
35.In shell script, which command is used to delete a file?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

  • rm is the command to remove/delete files in Unix/Linux.


WB JECA MCA PYQ
36.In Unix/Linux platform, which command is used to find out the difference between two files?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

  • diff compares two files line by line and shows differences.


WB JECA MCA PYQ
37.In Unix/Linux platform, which command is used to create a symbolic link?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

  • ln -s is used to create symbolic (soft) links in Linux.


WB JECA MCA PYQ
38.In Unix/Linux platform, which command is used to view the inode number of a file?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

  • ls -i displays the inode number of each file.


WB JECA MCA PYQ
39.In Unix/Linux platform, which command is used to specify the access mode for files?





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

  • chmod is used to change file permissions (read/write/execute).


WB JECA MCA PYQ
40.In Unix/Linux platform, ______ command is used to show current running processes.





Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

  • ps shows the list of currently running processes.


WB JECA MCA PYQ
41.In singly linked list, the time complexity for insertion at a particular node is:






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

  • Insertion after a given node in a linked list takes constant time O(1) (if pointer to that node is already available).



WB JECA MCA PYQ
42.In stack data structure, __________ operation is not permitted.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Enqueue is a queue operation, not allowed in stack.

WB JECA MCA PYQ
43.In tree data structure, the in-degree of root node is always __________.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

The root node has no incoming edges, so its in-degree is always 0.

WB JECA MCA PYQ
44.In binary tree data structure, using depth-first approach, preorder traversal means _______.






Go to Discussion

WB JECA MCA Previous Year PYQ WB JECA MCA JECA MCA 2023 PYQ

Solution

Preorder traversal visits root first, then left subtree, then right subtree.



WB JECA MCA


Online Test Series,
Information About Examination,
Syllabus, Notification
and More.

Click Here to
View More

WB JECA MCA


Online Test Series,
Information About Examination,
Syllabus, Notification
and More.

Click Here to
View More

Ask Your Question or Put Your Review.

loading...