Java tutorial
//package com.java2s; public class Main { public static long m11349a(double d, double d2) { return (long) (d - (Math.floor(d / d2) * d2)); } }