Cutting the fraction

Report a typo

Write a program that reads a number, cuts off its fractional part, and prints the integer part of the input number as the result.

Use Double as the input type and Long as the result type (values may be quite large).

Input: single number of type Double.

Output: single number of type Long.

Sample Input 1:

5.44

Sample Output 1:

5
Write a program in Kotlin
fun main() {
// write your code here
}
___

Create a free account to access the full topic