quiz 2nd/3rd year

Quiz
•
Computers
•
University
•
Medium
academicclub academicclub
Used 1+ times
FREE Resource
21 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
What is the purpose of the `_init_` method in a Python class?
2.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
Arrays in Java are dynamically allocated using the . . . . operator.
create
dynamic
arrayList
new
3.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
An Array in Java is a collection of elements of ___ data type.
Same
Different
4.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
Which of the following is correct about features of JavaScript?
It can not Handling dates and time.
JavaScript is a object-based scripting language.
JavaScript is not interpreter based scripting language.
All of the above
5.
MULTIPLE CHOICE QUESTION
1 min • 3 pts
public class Main {
public static void main(String args[]) {
int arr[][] = new int[4][];
arr[0] = new int[1];
arr[1] = new int[2];
arr[2] = new int[3];
arr[3] = new int[4];
int i, j, k = 0;
for (i = 0; i < 4; i++) {
for (j = 0; j < i + 1; j++) {
arr[i][j] = k;
k++;
}
}
for (i = 0; i < 4; i++) {
for (j = 0; j < i + 1; j++) {
System.out.print(" " + arr[i][j]);
k++;
}
System.out.println();
}
}
}
Compiler Error
0
1 2
3 4 5
6 7 8 9
0
0 0
0 0 0
0 0 0 0
9
7 8
4 5 6
0 1 2 3
6.
MULTIPLE CHOICE QUESTION
1 min • 2 pts
what is the output of this question?
class Test1 {
public
static void main(String[] args)
{
int x = 20;
System.out.println(x);
}
static
{
int x = 10;
System.out.print(x + " ");
}
}
10 20
20 10
10 10
20 20
7.
MULTIPLE CHOICE QUESTION
1 min • 2 pts
Predict the output?
public class Main {
public static void main(String args[]) {
int arr[] = {10, 20, 30, 40, 50};
for(int i=0; i < arr.length; i++)
{
System.out.print(" " + arr[i]);
}
}
}
10 20 30 40 50
Compiler Error
10 20 30 40
Create a free account and access millions of resources
Similar Resources on Wayground
20 questions
Code Junction 4

Quiz
•
University
17 questions
5-mavzu

Quiz
•
University
20 questions
EST102 : PROGRAMMING IN C TEST 1

Quiz
•
University
20 questions
JDBC

Quiz
•
University
19 questions
Java Basic 1 - Quiz

Quiz
•
8th Grade - University
20 questions
Review JavaScript

Quiz
•
11th Grade - University
20 questions
mile stone 2

Quiz
•
University
20 questions
OOP

Quiz
•
University
Popular Resources on Wayground
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
10 questions
Nouns, nouns, nouns

Quiz
•
3rd Grade
10 questions
9/11 Experience and Reflections

Interactive video
•
10th - 12th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
11 questions
All about me

Quiz
•
Professional Development
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
9 questions
Tips & Tricks

Lesson
•
6th - 8th Grade
Discover more resources for Computers
21 questions
Spanish-Speaking Countries

Quiz
•
6th Grade - University
20 questions
Levels of Measurements

Quiz
•
11th Grade - University
7 questions
Common and Proper Nouns

Interactive video
•
4th Grade - University
12 questions
Los numeros en español.

Lesson
•
6th Grade - University
7 questions
PC: Unit 1 Quiz Review

Quiz
•
11th Grade - University
7 questions
Supporting the Main Idea –Informational

Interactive video
•
4th Grade - University
12 questions
Hurricane or Tornado

Quiz
•
3rd Grade - University
7 questions
Enzymes (Updated)

Interactive video
•
11th Grade - University