Java Ceil ceil(float f)

Here you can find the source of ceil(float f)

Description

Rounds the given number up to an int.

License

Open Source License

Parameter

Parameter Description

Declaration

public static int ceil(float f) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    /**//from ww  w.java  2 s.c  o m
     * Rounds the given number up to an int.
     * @param float
     * @returns the ceiled value
     */
    public static int ceil(float f) {

        return (int) (f + (1f - f % 1f));
    }
}

Related

  1. ceil(double[] array)
  2. ceil(final double num)
  3. ceil(final double num)
  4. ceil(float f)
  5. ceil(float f)
  6. ceil(float floatNumber)
  7. ceil(float pX)
  8. ceil(float value)
  9. ceil(float value)