Create Account
Sign In
Toggle navigation
Home
Practice Exams
Official IQ Testing Hub
MCQ Learn
Board Exams
Learn
BISE Courses
Blog
About Us
Contact Us
00
:
59
:
00
Q:
1
/
65
🤖
Evaluating Your Answers
Please wait while our AI system evaluates your descriptive answers...
This may take a few moments.
⏳ Processing...
We're using advanced AI to provide detailed feedback on your answers.
Java Programming Mock Test 2
Exam Duration:
00:59:00
Java Programming Mock Test 2
: Question
1
of 65
What will be the output of the following PHP code ? <?php $color = "red"; echo "$color"; echo "$COLOR"; echo "$Color"; ?>
1 Mark(s)
Your Answer:
redredred
redredred
redred
redred
red
red
Error
Error
What will be the output of the following C# code snippet? class Program { static void Main(string[] args) { int[] nums = {3, 1, 2, 5, 4}; var ltAvg = from n in nums let x = nums.Average() where n
1 Mark(s)
Your Answer:
Run time error
Run time error
3
3
5
5
Compile time error
Compile time error
The ZooKeeper Data Directory contains files which are . . . . . . . . copy of the znodes stored by a particular serving ensemble.
1 Mark(s)
Your Answer:
transient
transient
read only
read only
persistent
persistent
none of the mentioned
none of the mentioned
Independent data marts are often created because an organization focuses on a series of short-term business objectives.
1 Mark(s)
Your Answer:
True
True
False
False
The first address in a block is used as the network address that represents the:
1 Mark(s)
Your Answer:
class network
class network
entity
entity
organization
organization
data codes
data codes
What is the purpose of the remove() method for lists?
1 Mark(s)
Your Answer:
Removes the specified element
Removes the specified element
Adds an element to the list
Adds an element to the list
Replaces an element in the list
Replaces an element in the list
Deletes the list
Deletes the list
Which loop in C# is more appropriate for iterating through an array?
1 Mark(s)
Your Answer:
for
for
while
while
do-while
do-while
foreach
foreach
Which of the following are examples of autotrophic organisms?
1 Mark(s)
Your Answer:
Fungi and virus
Fungi and virus
Virus and bacteria
Virus and bacteria
Green plants and some bacteria
Green plants and some bacteria
None of the above
None of the above
For your safety in a laboratory you should always adhere to:
1 Mark(s)
Your Answer:
safety rules
safety rules
chemicals
chemicals
compounds
compounds
apparatus
apparatus
Which of the following is not available in Font Spacing?
1 Mark(s)
Your Answer:
Normal
Normal
Loosely
Loosely
Condensed
Condensed
Expended Answer
Expended Answer
How many classification schemes have been developed for NFRs ?
1 Mark(s)
Your Answer:
Two
Two
Three
Three
Four
Four
Five
Five
A well-known helper plug-in for HTML is?
1 Mark(s)
Your Answer:
J-Query
J-Query
PHP
PHP
JavaScript
JavaScript
Java Applet
Java Applet
In the Java Collections Framework, which interface represents a last-in, first-out (LIFO) stack of elements?
1 Mark(s)
Your Answer:
`Stack`
`Stack`
`Queue`
`Queue`
`List`
`List`
`Deque`
`Deque`
Prefix femto has factor of:
1 Mark(s)
Your Answer:
1024
1024
10-21
10-21
1016
1016
10-15
10-15
Specific heat of water in joules is:
1 Mark(s)
Your Answer:
4180 J/kg. k
4180 J/kg. k
3900 J/kg.k
3900 J/kg.k
2430 J/kg.k
2430 J/kg.k
2220 J/kg.k
2220 J/kg.k
What is MQTT primarily used for?
1 Mark(s)
Your Answer:
User communication
User communication
System transfer
System transfer
Machine to Machine Communication
Machine to Machine Communication
Create connection
Create connection
Which of these methods is used to make raw MIME formatted string?
1 Mark(s)
Your Answer:
parse()
parse()
toString()
toString()
getString()
getString()
parseString()
parseString()
Ordering can be performed on:
1 Mark(s)
Your Answer:
1 attribute only
1 attribute only
Special attributes
Special attributes
Multiple attributes
Multiple attributes
No attributes
No attributes
Which one of the following cannot be used with the virtual keyword?
1 Mark(s)
Your Answer:
Constructor
Constructor
Destructor
Destructor
Member function
Member function
None of the above
None of the above
Determine Output: void main() { int i=0; for(;i++;printf("%d", i)); printf("%d", i); }
1 Mark(s)
Your Answer:
1
1
11
11
12
12
Error
Error
A Website is collection of
1 Mark(s)
Your Answer:
graphics
graphics
programs
programs
algorithms
algorithms
web pages
web pages
charts
charts
Users write the programs in which language?
1 Mark(s)
Your Answer:
Low-level Language
Low-level Language
High-Level Language
High-Level Language
Decimal-Format
Decimal-Format
Middle-Level Language
Middle-Level Language
MS Word and MS Excel are ______?
1 Mark(s)
Your Answer:
Applications software
Applications software
Operating systems
Operating systems
High level language
High level language
None of these
None of these
What will be the output of the following code: for i in range(5, 0, -1): print(i)
1 Mark(s)
Your Answer:
0 4 3 2 1
0 4 3 2 1
5 4 3 2 1
5 4 3 2 1
1 2 3 4 5
1 2 3 4 5
4 3 2 1 0
4 3 2 1 0
Point out the correct statement.
1 Mark(s)
Your Answer:
PaaS supplies the infrastructure
PaaS supplies the infrastructure
IaaS adds application development frameworks, transactions, and control structures
IaaS adds application development frameworks, transactions, and control structures
SaaS is an operating environment with applications, management, and the user interface
SaaS is an operating environment with applications, management, and the user interface
all of the mentioned
all of the mentioned
What is the difference between DELETE and TRUNCATE?
1 Mark(s)
Your Answer:
No difference
No difference
DELETE is faster
DELETE is faster
TRUNCATE is faster/DDL
TRUNCATE is faster/DDL
DELETE removes table structure
DELETE removes table structure
If the speed of a fluid element increases as the element travels along a horizontal streamlines, pressure of the fluid must:
1 Mark(s)
Your Answer:
decrease
decrease
increase
increase
become infinite
become infinite
become zero
become zero
Which of these events is generated when computer gains or loses input focus?
1 Mark(s)
Your Answer:
ComponentEvent
ComponentEvent
ContainerEvent
ContainerEvent
FocusEvent
FocusEvent
InputEvent
InputEvent
Which of the following is not a valid C++ identifier?
1 Mark(s)
Your Answer:
_variableName
_variableName
2ndVariable
2ndVariable
variable_name@
variable_name@
VariableName
VariableName
Both (B) and (C)
Both (B) and (C)
Consider a case where the failure of the system causes damage to the system itself or it data. What type of failure is being described here ?
1 Mark(s)
Your Answer:
Loss of service
Loss of service
Incorrect service delivery
Incorrect service delivery
System/data corruption
System/data corruption
None of the mentioned
None of the mentioned
Which of the following is the name of the node having child nodes?
1 Mark(s)
Your Answer:
Brother
Brother
Sister
Sister
Mother
Mother
Parent
Parent
The macro offset expands to a constant of type . . . . . . . .
1 Mark(s)
Your Answer:
size_t
size_t
print_t
print_t
ptrdiff_t
ptrdiff_t
null
null
Which of the following is use to view or print the data in organized manner?
1 Mark(s)
Your Answer:
Query
Query
Report
Report
Table
Table
Form
Form
The data warehouse DBMS needs to be the same DBMS used for the operational database.
1 Mark(s)
Your Answer:
True
True
False
False
The ________ measures the number of lost or garbled messages as a fraction of the total sent in the sampling period.
1 Mark(s)
Your Answer:
Residual Error Rate.
Residual Error Rate.
Transfer Failure Probability.
Transfer Failure Probability.
Connection release failure probability.
Connection release failure probability.
Connection establish.
Connection establish.
What is the significance of the Hadoop Rack Awareness feature?
1 Mark(s)
Your Answer:
Optimizes data locality by considering rack information
Optimizes data locality by considering rack information
Balances data across racks
Balances data across racks
Allocates more resources to specific racks
Allocates more resources to specific racks
Randomly assigns tasks to racks
Randomly assigns tasks to racks
What happens if an exception occurs but is not caught by the program in C#?
1 Mark(s)
Your Answer:
The program terminates with an unhandled exception
The program terminates with an unhandled exception
The program continues execution
The program continues execution
The program prompts the user for input
The program prompts the user for input
The program enters an infinite loop
The program enters an infinite loop
Law which states that the direction of an induced current is always such as to oppose the change in the circuit or the magnetic field that produces it is called:
1 Mark(s)
Your Answer:
Lenz's law
Lenz's law
Ohm's law
Ohm's law
Newton's law
Newton's law
Biot Savart Law
Biot Savart Law
Short Key Of Window Refreshing ?
1 Mark(s)
Your Answer:
F12
F12
F9
F9
F2
F2
F5
F5
Which of the following format is more compression-aggressive?
1 Mark(s)
Your Answer:
Partition Compressed
Partition Compressed
Record Compressed
Record Compressed
Block-Compressed
Block-Compressed
Uncompressed
Uncompressed
Which is the secondary storage device? ROM, CD-ROM, Hard Disk, Both B and C
1 Mark(s)
Your Answer:
ROM
ROM
CD-ROM
CD-ROM
Hard Disk
Hard Disk
Both B and C
Both B and C
Which keyword is commonly used in Cucumber feature files to define a scenario?
1 Mark(s)
Your Answer:
Then
Then
When
When
Given
Given
And
And
What will be the output of the following C# code? static void Main(string[] args) { int X = 6,Y = 2; X *= X / Y; Console.WriteLine(X); Console.ReadLine(); }
1 Mark(s)
Your Answer:
12
12
6
6
18
18
Compile time error
Compile time error
Files created with Lotus 1-2-3 have an extension?
1 Mark(s)
Your Answer:
123
123
DOC
DOC
WK1
WK1
XLS
XLS
Frequency of wave is defined as:
1 Mark(s)
Your Answer:
Ω/2π
Ω/2π
Ωπ
Ωπ
2 Ωπ
2 Ωπ
π/2 Ω
π/2 Ω
A workgroup typically comprises between 25 and 100 persons.
1 Mark(s)
Your Answer:
True
True
False
False
The type of comments in c# are:
1 Mark(s)
Your Answer:
Single Line Comment E.g. : //
Single Line Comment E.g. : //
Multiline Comments E.g.: /* */
Multiline Comments E.g.: /* */
XML Comments E.g. : ///
XML Comments E.g. : ///
All of the above
All of the above
In Access press . . . . . . . . to Paste the contents of the Clipboard in the upper- left corner of the selected section
1 Mark(s)
Your Answer:
CTRL+C
CTRL+C
CTRL+X
CTRL+X
CTRL+V
CTRL+V
None of these
None of these
The clause that is first evaluated to get a relation, is:
1 Mark(s)
Your Answer:
Select clause
Select clause
Define clause
Define clause
From clause
From clause
Where clause
Where clause
What is the default exception handler in C# called?
1 Mark(s)
Your Answer:
Standard Exception Handler
Standard Exception Handler
Unhandled Exception Handler
Unhandled Exception Handler
Global Exception Handler
Global Exception Handler
None of the above
None of the above
What is a lint?
1 Mark(s)
Your Answer:
C compiler
C compiler
Interactive debugger
Interactive debugger
Analyzing tool
Analyzing tool
C interpreter
C interpreter
Which of the following is an interface?
1 Mark(s)
Your Answer:
Time
Time
Timing
Timing
Performance
Performance
PerformanceTiming
PerformanceTiming
How does Dynamic Programming solve problems that exhibit "overlapping subproblems"?
1 Mark(s)
Your Answer:
By storing the results of subproblems to avoid redundant work.
By storing the results of subproblems to avoid redundant work.
By solving each subproblem independently.
By solving each subproblem independently.
By ignoring redundant subproblems.
By ignoring redundant subproblems.
By using a stack to manage subproblems.
By using a stack to manage subproblems.
What does the 'remove' function in C do?
1 Mark(s)
Your Answer:
Deletes a file
Deletes a file
Renames a file
Renames a file
Closes a file
Closes a file
Appends data to a file
Appends data to a file
What is the time complexity of searching for an element in a well-distributed hash table using chaining?
1 Mark(s)
Your Answer:
O(log n)
O(log n)
O(n)
O(n)
O(n log n)
O(n log n)
O(1)
O(1)
Which are the events that have default actions that can be canceled by event handlers?
1 Mark(s)
Your Answer:
Submit and form-related events
Submit and form-related events
Reset and form-related events
Reset and form-related events
Submit and reset events
Submit and reset events
None of the mentioned
None of the mentioned
Which of the following functions of Excel would you use to extract the substring 'Pak' from the word 'Pakistan'?
1 Mark(s)
Your Answer:
=LEFT()
=LEFT()
=SUBSTRING()
=SUBSTRING()
=FIND()
=FIND()
None of these
None of these
ADF stands for ________?
1 Mark(s)
Your Answer:
All Disc Feeder
All Disc Feeder
Automatic Document Feeder
Automatic Document Feeder
Automatic Document Finder
Automatic Document Finder
Automatic Disc Finder
Automatic Disc Finder
Which of the following is the correct way to settle down values into the structure variable 'e' defined in the following C# code snippet? struct emp { public String name; public int age; public Single sal; } emp e = new emp();
1 Mark(s)
Your Answer:
e.name = "Jone"; e.age = 24; e.sal = 200;
e.name = "Jone"; e.age = 24; e.sal = 200;
With emp e { .name = "Jone"; .age = 24; .sal = 200; }
With emp e { .name = "Jone"; .age = 24; .sal = 200; }
name = "Jone"; age = 24; sal = 200;
name = "Jone"; age = 24; sal = 200;
All of the mentioned
All of the mentioned
Gravitational force is defined as the force of attraction between:
1 Mark(s)
Your Answer:
two masses
two masses
three masses
three masses
magnets
magnets
two poles
two poles
In a periodic table, the row of elements is called:
1 Mark(s)
Your Answer:
sets
sets
group
group
column
column
periods
periods
What will happen while using pass by reference?
1 Mark(s)
Your Answer:
The values of those variables are passed to the function so that it can manipulate them
The values of those variables are passed to the function so that it can manipulate them
The location of variable in memory is passed to the function so that it can use the same memory area for its processing
The location of variable in memory is passed to the function so that it can use the same memory area for its processing
The function declaration should contain ampersand (& in its type declaration)
The function declaration should contain ampersand (& in its type declaration)
The function declaration should contain $
The function declaration should contain $
Typically, there should be at least two different copies of the database schema used in the redesign process.
1 Mark(s)
Your Answer:
True
True
False
False
Which of the following is the file extension of the PowerPoint application?
1 Mark(s)
Your Answer:
.ppt
.ppt
.jpg
.jpg
.html
.html
.docs
.docs
Interposes Communication (IPC) related system calls used by Linux for:
1 Mark(s)
Your Answer:
Termination
Termination
Development
Development
Execution
Execution
Communication
Communication
Previous
Mark For Review & Next
Next
Clear Answer
Finish
© Copyright © 2020 ALGOPK . All Rights Reserved.