CUET Exam  >  CUET Tests  >  CUET Mock Test Series  >  Computer Science: CUET Mock Test - 5 - CUET MCQ

Computer Science: CUET Mock Test - 5 - CUET MCQ


Test Description

30 Questions MCQ Test CUET Mock Test Series - Computer Science: CUET Mock Test - 5

Computer Science: CUET Mock Test - 5 for CUET 2025 is part of CUET Mock Test Series preparation. The Computer Science: CUET Mock Test - 5 questions and answers have been prepared according to the CUET exam syllabus.The Computer Science: CUET Mock Test - 5 MCQs are made for CUET 2025 Exam. Find important definitions, questions, notes, meanings, examples, exercises, MCQs and online tests for Computer Science: CUET Mock Test - 5 below.
Solutions of Computer Science: CUET Mock Test - 5 questions in English are available as part of our CUET Mock Test Series for CUET & Computer Science: CUET Mock Test - 5 solutions in Hindi for CUET Mock Test Series course. Download more important topics, notes, lectures and mock test series for CUET Exam by signing up for free. Attempt Computer Science: CUET Mock Test - 5 | 50 questions in 45 minutes | Mock test for CUET preparation | Free important questions MCQ to study CUET Mock Test Series for CUET Exam | Download free PDF with solutions
Computer Science: CUET Mock Test - 5 - Question 1

Which character is used in Python to make a single line comment?

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 1

In Python, we use the hash symbol # to write a single-line comment.

Computer Science: CUET Mock Test - 5 - Question 2

_______ type is returned by the readlines() method of the file object.

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 2

The correct answer is List of strings

Key PointsThe readlines() method of the file object in Python returns a list of strings. (Option 3)

  • Opening the File: You use the open() function to open a file in read mode ("r"). This creates a file object that represents the open file.
  • Calling readlines(): You call the readlines() method on the file object. This method reads the entire contents of the file line by line, treating each line as a separate string.
  • Returning the List: The readlines() method returns a list where each element in the list is a string representing a line from the file. The newline character (\n) is typically included at the end of each line in the list.
Computer Science: CUET Mock Test - 5 - Question 3

What is the length of MAC Address in bits?

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 3

The correct answer is 48 bits

Key Points

  • The MAC address is a unique 12-digit hexadecimal numbers (48 bits in length) hardware address associated with a network adapter card, which is engraved on NIC at the time of manufacturing.
  • The can be physically identified on the network using its MAC address is a permanent address and cannot be changed under any circumstances it means two devices cannot have the same MAC address.
  • It is 12-digit hexadecimal numbers (48 bits in length) format on each device and is represented by Colon-Hexadecimal notation.
  • Example: 00:0b:45:9e:87:46.
Computer Science: CUET Mock Test - 5 - Question 4

The like operator makes use of two wild card characters underscore ( _ ) and %. Which of the following statement(s) is / are correct w.r.t these operators?

A. % represents zero, one or multiple characters

B. Underscore represents zero, one or multiple characters

C. Underscore represents only multiple characters

D. Underscore represents exactly a single character

E. % represents zero character

Choose the most appropriate answer from the options given below:

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 4

The correct answer is A and D only

Key Points

  • A. % represents zero, one, or multiple characters
    • This is correct. The percent sign (%) is a wildcard that can match any sequence of characters, including an empty string (zero characters).
  • B. Underscore represents zero, one, or multiple characters
    • This is incorrect. The underscore (_) represents exactly one character, not zero or multiple characters.
  • C. Underscore represents only multiple characters
    • This is incorrect for the same reason as B. The underscore represents only one character.
  • D. Underscore represents exactly a single character
    • This is correct. The underscore always matches exactly one character in the pattern.
  • E. % represents zero characters
    • This is partially correct. While the percent sign can match zero characters, it can also match one or more characters, so this statement doesn't fully capture its functionality.

Therefore, the only correct statements are A and D, making option 1 the right choice.

Computer Science: CUET Mock Test - 5 - Question 5

Given below are two statements: one is labelled as Assertion A and other is labelled as Reason R.

Assertion A : Wi - Fi gives users the flexibility to move around within the network area while being connected to the network.

Reason R : Wireless network connects communicating devices to each other without any wire.

In the light of the above statements, choose the most appropriate answer from the options given below:

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 5

The correct answer is Both A and R are correct and R is the correct explanation of A

Key Points

  • Assertion A (A is correct): Wi-Fi offers flexibility in movement. Because it's wireless, you can connect to the internet and move around within the network's coverage area without being tethered to a physical cable.
  • Reason R (R is correct): A wireless network, as stated in Reason R, eliminates the need for wires to connect devices. This directly contributes to the flexibility highlighted in Assertion A.

Therefore, both A and R are true, and R accurately explains why A is true. Wi-Fi's wireless nature allows for the movement freedom mentioned in Assertion A.

Computer Science: CUET Mock Test - 5 - Question 6

Choose the Network Topology that requires a central controller.

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 6

The correct answer is Star

Key PointsNetwork topology refers to how the nodes and links in a network are arranged. A network node is a device that can send, receive, store, or forward data. A network link connects nodes and may be either cabled or wireless links.

  • Understanding topology types provides the basis for building a successful network. There are a number of topologies but the most common are bus, ring, star, and mesh:

  1. A bus network topology is when every network node is directly connected to the main cable.
  2. In a ring topology, nodes are connected in a loop, so each device has exactly two neighbors. Adjacent pairs are connected directly; non-adjacent pairs are connected indirectly through multiple nodes.
  3. In a star network topology, all nodes are connected to a single, central hub and each node is indirectly connected through that hub.
  4. A mesh topology is defined by overlapping connections between nodes. You can create a full mesh topology, where every node in the network is connected to every other node. You can also create a partial mesh topology in which only some nodes are connected to each other and some are connected to the nodes with which they exchange the most data. Full mesh topology can be expensive and time-consuming to execute, which is why it's often reserved for networks that require high redundancy. Partial mesh provides less redundancy but is more cost-effective and simpler to execute.
  5. A tree topology is a special type of structure where many connected elements are arranged like the branches of a tree. For example, tree topologies are frequently used to organize the computers in a corporate network or the information in a database.
Computer Science: CUET Mock Test - 5 - Question 7

What would be the prefix notation for the given equation?

(a+(b/c) *(d^e)-f)

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 7

The correct answer is option 4.

Concept:

Infix:

An infix expression prints the operand 1, operator, and operand 2 respectively.

Postfix:

A Postfix expression prints the operand 1, operand 2, and operator respectively.

Prefix:

A Prefix expression prints the operator operand 1, and operand 2 respectively.

Converse postfix:

A converse postfix expression prints the operand 2, operand 1, and operator respectively.

Converse infix:

A converse infix expression prints the operand 2, operator, and operand 1 respectively.

Converse prefix:

A converse prefix expression prints the operator, operand 2, and operand 1 respectively.

Explanation:

The given infix is,

(a+(b/c) *(d^e)-f)

() is highest prority

The inner (b/c) is excutes first,

operand 1=b

operand 2=c

Operator= /

(a+/bc *(d^e)-f)

The inner (d^e) is excutes next,

operand 1=d

operand 2=e

Operator= ^

(a+/bc *^de-f)

The highest operator is * than +, -

operand 1=/bc

operand 2=^de

Operator= *

(a+*/bc^de-f)

The highest operator is + than -.

operand 1=a

operand 2= */bc^de

Operator= +

(+a*/bc^de-f)

operand 1=+a*/bc^de

operand 2= f

Operator= There is no start phase in Virus Life Cycle.

The prefix is -+a*/bc^def.

Hence the correct answer is -+a*/bc^def.

Computer Science: CUET Mock Test - 5 - Question 8

Which of the following features are associated with SQL?
A. SQL is a case-sensitive language.
B. Allows for the creation of views and tables.
C. It does not permit the handling of data in a relational database management system (RDBMS).
D. Facilitates the imposition of constraints to ensure the integrity of the data.

Choose the correct answer from the options given below:

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 8

The correct answer is B and D only

Key Points

  • A. While certain implementations of SQL may be case-sensitive for identifiers (e.g., table or column names), the SQL language itself is not inherently case-sensitive, especially for its keywords (e.g., SELECT, FROM, WHERE), making statement A misleading/false.
  • B. SQL allows for the creation of views and tables, enabling structured storage and targeted data access, making statement B true.
  • C. SQL is specifically designed for handling data in relational database management systems (RDBMS), giving it powerful functionality for data management, making statement C false.
  • D. Constraints (PRIMARY KEY, FOREIGN KEY, UNIQUE, NOT NULL, CHECK) are a fundamental aspect of ensuring data integrity within an SQL database, making statement D true.

Hence, the correct answer is 2) B and D only.

Computer Science: CUET Mock Test - 5 - Question 9
Which part of database holds only one type of information?
Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 9

The correct answer is Field

Key Points

  • Report:
    • A report in the context of a database represents a formatted and organized presentation of data.
    • Reports may be generated from database information, often following a user-specified query, to present data in a way that is easy to understand.
    • They typically gather data from multiple fields and records, often across different tables.
  • Field:
    • A field represents the smallest unit of data in a database. It holds only one specific type of information.
    • In a table, a field corresponds to a column. For instance, in a database table that stores employee data, you might have fields such as "EmployeeID", "FirstName", "LastName", "Email", each of which holds one specific type of information.
  • File:
    • In a database, a file is a collection of related records. In older, file-based databases this was a more common term.
    • In modern, relational databases, we commonly refer to such a collection of records as a table. These contain multiple types of information as they consist of multiple fields.
  • Record:
    • A record represents a single unit of related data fields in a database. In a table, a record corresponds to a row.
    • For instance, each employee within an "Employees" table would have their own record, and this record would contain multiple types of information (the employee's ID, name, email, etc.), each stored in its own field.
Computer Science: CUET Mock Test - 5 - Question 10
Which of the following is an atomic attribute?
Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 10

The correct answer is Age

Key PointsAn atomic attribute is an attribute that cannot be divided any further. From the options provided:

  • Date of birth: Not atomic, as it can be divided into day, month, and year.
  • Telephone number: Not atomic, Telephone Numbers begin with the area code, then one digit for the operator code, then six digits for the primary telephone number.
  • Name: Not atomic, as it can be divided into first name and last name.
  • Age: Generally considered atomic, as it is usually represented as a single numerical value.

So, the atomic attributes from the given options are: 4) Age

Computer Science: CUET Mock Test - 5 - Question 11

Which of the following is valid order for SQL query evaluation?

Note: Options order from left to right.

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 11

The correct answer is option 3.

Concept:

The SQL order of execution specifies the order in which query clauses are executed. Some of the most common query issues might be easily avoided if people had a better understanding of the SQL order of execution, often known as the SQL order of operations.

Order or SQL query evaluation:

  1. From: Cartesian product of tables.
  2. Where: Select the rows.
  3. Group by: Divide the rows into groups.
  4. Having: Select the groups.
  5. Expressions: Expressions In select are evaluated.
  6. Distinct: Distinct in select (Eliminate the duplicates).
  7. Ser-Operations: (Union, intersect, Except)
  8. Order By: Sort the rows.

Hence the correct answer is Where, Having, Distinct, Order By.

Computer Science: CUET Mock Test - 5 - Question 12

Which of the following is the correct extension of the Python file?

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 12

" .py " is the correct extension of the Python file.
.PY file is a program or script written in Python, which is an interpreted object-oriented programming language. It may be written in a text editor and may be edited, but it must be run using a Python interpreter. .PY files are often used to program web servers and other administrative computer systems.

Computer Science: CUET Mock Test - 5 - Question 13

Two statements are given below, one is Assertion (A) and the other is Reason (R). Read the statements carefully and choose the correct answer.

Assertion (A): Linear search is an efficient searching algorithm for large arrays.
Reason (R): Linear search has a time complexity of O(n).

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 13

Linear search has a time complexity of O(n), which means that it takes linear time to search an array. This makes it inefficient for large arrays, as the time taken to search the array grows linearly with the size of the array. Therefore, whether linear search is a simple and easy-to-implement algorithm, it is not efficient for large arrays.

Computer Science: CUET Mock Test - 5 - Question 14

Which language is used to access and manipulate databases?

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 14

SQL stands for Structured Query Language. It lets you access and manipulate databases and became a standard of the American National Standards Institute (ANSI) in 1986, and of the International Organization for Standardization (ISO) in 1987.

Computer Science: CUET Mock Test - 5 - Question 15

Directions: Match the contents under List I with those under List II.

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 15

Primary key is a key that uniquely identifies each record in a table.
Foreign key is used to establish a relationship between two tables.
Candidate key can be used as a primary key and is unique for each record.
Composite key is composed of two or more columns and is used to uniquely identify each record in a table.

Computer Science: CUET Mock Test - 5 - Question 16

A node that forwards data packets from one network to their destination in another network is called:

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 16

A router is a networking device that forwards data packets between computer networks. Routers perform the traffic directing functions on the Internet. Data sent through the internet, such as a web page or email, is in the form of data packets.

Computer Science: CUET Mock Test - 5 - Question 17

Which of the following options can be used to read the first line of a text file Myfile.txt?

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 17

The 'readline()' function can be used to read the first line of a text file Myfile. txt. Hence, the correct answer is option 3.

Computer Science: CUET Mock Test - 5 - Question 18

If we want to add more contents in an existing file, file must be opened in............mode.

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 18

The "a" mode allows you to open a file to append some content to it. If we want to add a new line to it, we can open it using the "a" mode (append) and then, call the write() method, passing the content that we want to append as argument.

Computer Science: CUET Mock Test - 5 - Question 19

Two statements are given below:

Statement I: ALTER TABLE statement is used to add a new column to an existing table in SQL.
Statement II: INSERT Row statement is used to insert the Row to an existing table in SQL.

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 19

ALTER TABLE statement is used to add a new column to an existing table in SQL. INSERT ROW statement is not used to insert the Row to an existing table in SQL. INSERT INTO is used to insert the Row.

Computer Science: CUET Mock Test - 5 - Question 20

It is possible to create a loop using goto statement in python?

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 20

No, Python does not support labels and goto. It's a (highly) structured programming language.

Computer Science: CUET Mock Test - 5 - Question 21

What will be the output of following Python code?

str1="Information"
print(str1[2:8])

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 21

Concept of slicing is used in this question. In string slicing, the output is the substring starting from the first given index position i.e. 2 to one less than the second given index position i.e. (8 - 1 = 7) of the given string str1. Hence, the output will be "format".

Computer Science: CUET Mock Test - 5 - Question 22

The process of identifying a slot for the second and further items in the hash table in the event of collision, is called _______.

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 22

The process of identifying a slot for the second and further items in the hash table in the event of collision, is called collision resolution.

Computer Science: CUET Mock Test - 5 - Question 23

Which of the following is/are the advantage(s) of a database management system?

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 23

Yes, All (1), (2) and (3) are the advantages of a database management system.

Computer Science: CUET Mock Test - 5 - Question 24

Directions: Match the contents under List I with those under List II.

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 24

The binary heap data structure takes O(n) time to build, and the repeated extraction and placement operations take O(log n) time. Hence, the total worst-case time complexity of Heap Sort is O(n log n).

  • Selection Sort: O(n2) - This occurs when the array is in reverse sorted order or any other order, as the algorithm has to traverse the entire array to find the minimum element repeatedly.
  • Radix Sort: O(nk), where n is the size of the array and k is the number of digits in the largest number.
  • Count Sort: O(n+k), where n is the number of elements to be sorted, and k is the range of input values.
Computer Science: CUET Mock Test - 5 - Question 25

What is the output of the following if statement

a, b = 12, 5
if a + b:
print('True')
else:
print('False')

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 25

In Python, any non-zero value is considered True. So, it will evaluate to true.

Computer Science: CUET Mock Test - 5 - Question 26

Your teacher has given you a method/function FilterWords() in python which read lines from a text file NewsLetter.TXT, and display those words, which are lesser than 4 characters. Your teachers intentionally kept few blanks in between the code and asked you to fill the blanks so that the code would run to find desired result. Do the needful with the following python code:

def FilterWords():
c=0
file=open('NewsLetter.TXT', '_____') #Statement-1
line = file._____ #Statement-2
word = _____ #Statement-3
for c in word:
if _____: #Statement-4
print(c)
_________ #Statement-5

FilterWords()

Q. Write the mode of opening the file in Statement-1.

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 26

r mode is used to open the file.
'NewsLetter.TXT'. It opens a file in reading mode.

Computer Science: CUET Mock Test - 5 - Question 27

Your teacher has given you a method/function FilterWords() in python which read lines from a text file NewsLetter.TXT, and display those words, which are lesser than 4 characters. Your teachers intentionally kept few blanks in between the code and asked you to fill the blanks so that the code would run to find desired result. Do the needful with the following python code:

def FilterWords():
c=0
file=open('NewsLetter.TXT', '_____') #Statement-1
line = file._____ #Statement-2
word = _____ #Statement-3
for c in word:
if _____: #Statement-4
print(c)
_________ #Statement-5

FilterWords()

Q. Fill in the blank in Statement-3 to read data word by word.

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 27

line.split( ) method fits the blank in Statement-3 to read data word by word.

Computer Science: CUET Mock Test - 5 - Question 28

Your teacher has given you a method/function FilterWords() in python which read lines from a text file NewsLetter.TXT, and display those words, which are lesser than 4 characters. Your teachers intentionally kept few blanks in between the code and asked you to fill the blanks so that the code would run to find desired result. Do the needful with the following python code:

def FilterWords():
c=0
file=open('NewsLetter.TXT', '_____') #Statement-1
line = file._____ #Statement-2
word = _____ #Statement-3
for c in word:
if _____: #Statement-4
print(c)
_________ #Statement-5

FilterWords()

Q. Fill in the blank in Statement-5 to close the file.

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 28

file.close( ) is used to close the file. It is important to close the file as soon as you have finished your work with the file.

Computer Science: CUET Mock Test - 5 - Question 29

Your teacher has given you a method/function FilterWords() in python which read lines from a text file NewsLetter.TXT, and display those words, which are lesser than 4 characters. Your teachers intentionally kept few blanks in between the code and asked you to fill the blanks so that the code would run to find desired result. Do the needful with the following python code:

def FilterWords():
c=0
file=open('NewsLetter.TXT', '_____') #Statement-1
line = file._____ #Statement-2
word = _____ #Statement-3
for c in word:
if _____: #Statement-4
print(c)
_________ #Statement-5

FilterWords()

Q. Fill in the blank in Statement-2 to read the data from the file.

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 29

file.read( ) is fits the blank in Statement-2 as this method returns a string containing all characters in a file.

Computer Science: CUET Mock Test - 5 - Question 30

Your teacher has given you a method/function FilterWords() in python which read lines from a text file NewsLetter.TXT, and display those words, which are lesser than 4 characters. Your teachers intentionally kept few blanks in between the code and asked you to fill the blanks so that the code would run to find desired result. Do the needful with the following python code:

def FilterWords():
c=0
file=open('NewsLetter.TXT', '_____') #Statement-1
line = file._____ #Statement-2
word = _____ #Statement-3
for c in word:
if _____: #Statement-4
print(c)
_________ #Statement-5

FilterWords()

Q. Fill in the blank in Statement-4, which displays the word having lesser than 4 characters.

Detailed Solution for Computer Science: CUET Mock Test - 5 - Question 30

len(c)<4 is used fits the blank in Statement-4, which displays the word having lesser than 4 characters.

View more questions
8 docs|148 tests
Information about Computer Science: CUET Mock Test - 5 Page
In this test you can find the Exam questions for Computer Science: CUET Mock Test - 5 solved & explained in the simplest way possible. Besides giving Questions and answers for Computer Science: CUET Mock Test - 5, EduRev gives you an ample number of Online tests for practice
Download as PDF