Final Exam Information

Final Exam Information

University

36 Qs

quiz-placeholder

Similar activities

Java/ Фінальний тест

Java/ Фінальний тест

9th Grade - Professional Development

31 Qs

preassessment frontend for A3 belgaum

preassessment frontend for A3 belgaum

University

33 Qs

Introduction to Research Methodology - Part A

Introduction to Research Methodology - Part A

University

40 Qs

Module4QuizLabWth230

Module4QuizLabWth230

University

40 Qs

Mid Test Ergonomi and MMH

Mid Test Ergonomi and MMH

University

40 Qs

AP Psychology - Cognition #2

AP Psychology - Cognition #2

11th Grade - Professional Development

41 Qs

Kuis HTML, CSS, dan JavaScript

Kuis HTML, CSS, dan JavaScript

University

32 Qs

CC102 1st Sem Quizz ni prof. Aaron 🥸

CC102 1st Sem Quizz ni prof. Aaron 🥸

University

36 Qs

Final Exam Information

Final Exam Information

Assessment

Quiz

Science

University

Medium

Created by

Folarin Omisakin

Used 3+ times

FREE Resource

36 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What must be included at the top of a Java program to use a Scanner for user input?

import java.util.Scanner;

package java.util.Scanner;

include java.util.Scanner;

using java.util.Scanner;

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which package in Java contains the Scanner class?

java.lang

java.util

java.io

java.net

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of the Java code 'Scanner input = new Scanner(System.in);'?

To create a file

To print a message to the console

To read input from the user

To close a program

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which method is used to read a double value from the user in Java?

nextLine()

nextDouble()

nextInt()

nextBoolean()

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will the output be if the user enters '5.5' after the statement 'System.out.println("Enter the radius: ");' is executed?

Enter the radius: 5.5

Error

5.5

Enter the radius:

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does the "+=" operator do in programming?

Multiplies and assigns the value

Divides and assigns the value

Adds and assigns the value

Subtracts and assigns the value

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which operator is used for division assignment?

%=

*=

-=

/=

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?