Here you can find the source of longToIntArray(long value)
public static int[] longToIntArray(long value)
//package com.java2s; //License from project: Open Source License public class Main { public static int[] longToIntArray(long value) { int[] digits = Long.toString(value).chars().map(c -> c -= '0').toArray(); return digits; }// w ww .j av a 2s.c o m }