Table of Contents
Control flow in programming
🔒 Please log in to unlock this course.
ONLINE CLASSES BY RUMMAN ANSARI
Stuck on a Java Program? Ask Your Doubt Directly
Book a one-to-one session to get your questions answered, or message on WhatsApp for live online classes in Java Programming.
- 1:1 Mentoring
- Doubt Clearing
- Interview Preparation
Related Questions
Question 1
Given the value of a variable, write a statement, without using if construct, which will produce…
Locked. Enroll to open this question.
Related Assignments
Assignment 1
Write a Java program to find out whether a year (entered in 4-digit number…
Locked. Enroll to open this assignment.
Assignment 2
Write a java program to compute cosine series.
Locked. Enroll to open this assignment.
Assignment 3
Write a java program to find whether a given number is odd or even or prime.
Locked. Enroll to open this assignment.
Assignment 4
Write a java program to generate divisors of an integer.
Locked. Enroll to open this assignment.
Assignment 5
Write a java program to check whether the given number is palindrome or not.
Locked. Enroll to open this assignment.
Assignment 6
Write a short program to find whether the given character is a digit or a…
Locked. Enroll to open this assignment.
Assignment 7
Write a short program to input a digit and print it in words.
Locked. Enroll to open this assignment.
Assignment 8
Write a Java program to print every integer between 1 and n divisible by m.…
Locked. Enroll to open this assignment.
Assignment 9
During a special sale at a store, a 10% discount is taken on purchases over ?…
Locked. Enroll to open this assignment.
Assignment 10
Write a java program to print fibonacci series... The number of terms required,…
Locked. Enroll to open this assignment.
Assignment 11
Given three numbers A, B and C, write a program to write their values in…
Locked. Enroll to open this assignment.
Assignment 12
Write a java program to print table of a given number.
Locked. Enroll to open this assignment.
MCQ Section
MCQ 1
Which of the following is a valid Java statement?
Locked. Enroll to open this MCQ.
MCQ 2
What does the if statement do?
Locked. Enroll to open this MCQ.
MCQ 3
Which statement allows for multiple selections in Java?
Locked. Enroll to open this MCQ.
MCQ 4
What is the purpose of the break statement in a switch?
Locked. Enroll to open this MCQ.
MCQ 5
Which statement correctly compares if and switch?
Locked. Enroll to open this MCQ.
MCQ 6
Which of the following is not a valid switch case label?
Locked. Enroll to open this MCQ.
MCQ 7
What does a nested if statement allow you to do?
Locked. Enroll to open this MCQ.
MCQ 8
Which loop is entry-controlled?
Locked. Enroll to open this MCQ.
MCQ 9
How many times is the code inside a do-while loop guaranteed to execute?
Locked. Enroll to open this MCQ.
MCQ 10
Which loop statement is used for iterating with a known number of iterations?
Locked. Enroll to open this MCQ.
MCQ 11
What is a labelled loop used for in Java?
Locked. Enroll to open this MCQ.
MCQ 12
What does the continue statement do in a loop?
Locked. Enroll to open this MCQ.
MCQ 13
Which statement is used to exit from a loop?
Locked. Enroll to open this MCQ.
MCQ 14
In which type of loop can a labelled continue statement be used?
Locked. Enroll to open this MCQ.
MCQ 15
What does a labelled break statement do in Java?
Locked. Enroll to open this MCQ.
MCQ 16
What defines the scope of a variable in Java?
Locked. Enroll to open this MCQ.
MCQ 17
Which of the following is true about variable visibility in Java?
Locked. Enroll to open this MCQ.
MCQ 18
Which of the following variables has block scope?
Locked. Enroll to open this MCQ.
Get Java Programming Language updates by email
Short, practical lessons and course updates from Rumman Ansari. No spam.