File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Arduino in Action
this week in the
A special promo:
Enter your blog post or vote on a blogger to be featured in an upcoming Journal
seperate numbers from float number
Joined: Sep 21, 2009
Nov 19, 2012 19:41:50
I have a number var num=1.234 i want to take the numbers before and after the dot i.e 1 and 2, save it in two variables like before=1,after=2, how can i achieve this. please help me.
thanks in advance.
Author and ninkuma
Joined: Jan 10, 2002
Nov 19, 2012 20:35:12
Did you look for help from the Math object?
Books by Bear
I agree. Here's the link:
- it saves me about five hours per week
subject: seperate numbers from float number
Help with displaying output
help with counting occurrences of elements in an array
How to make sure that file has been read.
java decimal multiplication
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2013