Giter VIP home page Giter VIP logo

list-of-java-programs-for-practice-'s Introduction

List-of-Java-Programs-for-Practice-

Java programming exercises: To learn any programming language you have to practice the programs, this is one of the best and faster ways to learn a programming language.

Java is an object oriented programming java that James Gosling designed at Sun Microsystems, Inc.

This webpage contains java programs for practice on various java topics such as Java string programs, control statements, Java Array Programs, Java loops programs, functions, arrays, etc. All the following java programs are tested and provided with the output.

Basic Java programs Practice | Java Coding Practice with examples

Question 1 --> Write a Java program to print ‘Hello World!’ on screen ?

Solution:- image

Question 2 --> Write a Java program to print the sum of two numbers ?

Solution :- image

Question 3 --> Write a Java program that takes two numbers and display the product of two numbers ?

Solution :- image

Question 4 --> Write a Java program to print the sum, multiply, subtract, divide and remainder of two numbers ?

Solution :- image

Question 5 --> Write a Java program that takes five numbers as input to calculate and print the average of the numbers ?

Solution :- image

Question 6 --> Write a Java program to swap two variables ?

Solution :- image

Question 7 --> Write a Java program to convert a decimal number to binary numbers ?

Solution :-

Question 8 --> Write a Java program to convert a binary number to decimal number ?

Solution :-

Question 9 --> Write a Java program to check whether Java is installed on your computer or not ?

Solution :-

Question 10 --> Write a Java program and compute the sum of the digits of an integer ?

Solution :-

Question 11 --> Write a Java program to compare two numbers ?

Solution :-

Question 12 --> Write a Java program to count the letters, spaces, numbers and other characters of an input string ?

Solution :-

Question 13 --> Write a Java program to print the ascii value of a given character ?

Solution :-

Question 14 --> Write a Java program that accepts an integer (n) and computes the value of n+nn+nnn ?

Solution :-

Question 15 --> Write a Java program to display the system time ?

Solution :-

Question 16 --> Write a Java program to print the odd numbers from 1 to 20 ?

Solution :-

Question 17 --> Write a Java program to print the even numbers from 1 to 20 ?

Solution :-

Question 18 --> Write a Java program to convert a string to an integer ?

Solution :-

Question 19 --> Write a Java program to convert seconds to hour, minute and seconds ?

Solution :-

Question 20 --> Write a Java program to compute the sum of the first 100 prime numbers ?

Solution :-

Question 21 --> Write a Java program to swap the first and last elements of an array and create a new array ?

Solution :-

Question 22 --> Write a Java program to count the number of even and odd elements in a given array ?

Solution :-

Question 23 --> Write a Java program to compute the square root of an given integer ?

Solution :-

Question 24 --> Write a Java program to check if a positive number is a palindrome or not ?

Solution :-

Question 25 --> Write a Java program to add two numbers without using any arithmetic operators ?

Solution :-

Question 26 --> Write a Java program to add all the digits of a given positive integer ?

Solution :-

list-of-java-programs-for-practice-'s People

Contributors

supercool-coder avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.