package com.company;
import java.util.Scanner;
public class Program20 {
public static void main(String[] args) {
Scanner put = new Scanner(System.in);
System.out.println("please enter a first float number:");
float a=put.nextFloat();
System.out.println("please enter a second float number:");
float b=put.nextFloat();
if(a==b)
{
System.out.println("you enter same floating point number");
}
else
{
System.out.println("you enter different numbers");
}
}
}
Hi Friends ! You are on HR Developers website. Here you can find the codes of different languages like c ,c++ , java, pyton and many other languages.
Wednesday, June 16, 2021
Java program that reads in two floating-point numbers and tests whether they are the same or different (Java) (183)
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment