java - Fixed Point Numbers -


I got stuck in a project in my project for Java class.

We have to create a code that will convert a number into a fixed point number. I got that part right, but where I am stuck, it is in the part of our work of mathematics. We have to split with adding, subtracting, multiple w / (scalar (float) method, and scalar (float) method.

Even if I have a code I can say that the second number is the right direction for getting the output and adding two numbers. I

, 2); F value; int value 2; public fixed number (Int value) {this.value = value & lt; & lt; 6;} Public fixed number (int integral, float decimal) {this.value = (integral & lt; & lt; 6) + (private) % 1 * 50);} Public Fixed Number (float value) {this.value = ((int) value > + "." + ((Value and reciprocity) * 2); // Return "" + ((value << 26)>>

for each action in your fixed number Class This method will work on the existing number of object numbers ( this ) and passed parameters. Adding a public fixed dum to [02] connects two numbers and returns the result} Public FixedDumer Multiplication (Fixed number to multiply) {// multiply two numbers and gives results} // ... etc. ..

You can look for an example to see.

Comments

Popular posts from this blog

Python SQLAlchemy:AttributeError: Neither 'Column' object nor 'Comparator' object has an attribute 'schema' -

java - How not to audit a join table and related entities using Hibernate Envers? -

mongodb - CakePHP paginator ignoring order, but only for certain values -