Click here to Skip to main content
15,900,511 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
if user enter as input-2.0000 float value.output will be true. if user input value like 2.4378 .means digit after point except 0,output should be false.

What I have tried:

I tried float =x.766
x.oo return true.
Updated 26-Dec-17 19:41pm
Patrice T 27-Dec-17 1:05am    
What are you talking about ?
Do you have a question ?

1 solution

Explore Regex, such as
could be want you are looking for. Ask Google for the use of regex in Java. Some online regex tester should help RegexPlanet: online regular expression testing for Java[^]
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900