Questions for Practice 2
Java Practice Questions
- Write a Java program to check if the number is odd or even.
- Write a Java program to check whether a character is a vowel or consonant.
- Write a Java program to check whether a number is positive, negative, or zero.
- Write a Java program to print your name 100 times.
- Write a Java program to round a number in n decimal places.
- Write a Java program to calculate the sum of natural numbers.
- Write a Java program to generate multiplication tables of 5.
- Write a Java program to generate multiplication tables of 1 -9.
- Write a Java program to create a simple calculator using a switch case.
- Write a Java program to print 1 to 100 but not 41.