how to convert double into long code example Example: java double to long long num = Double.valueOf(d).longValue()