Here you can find the source of longToBinaryStringUnsigned(long value)
public static String longToBinaryStringUnsigned(long value)
//package com.java2s; /**/*from w w w. j av a2 s.c o m*/ * Copyright (c) 2014 Sa?l Pi?a <sauljabin@gmail.com>. * * This file is part of GeneticAlgorithm. * * GeneticAlgorithm is licensed under The MIT License. * For full copyright and license information please see the LICENSE file. */ public class Main { public static String longToBinaryStringUnsigned(long value) { return Long.toBinaryString(Math.abs(value)); } public static String longToBinaryStringUnsigned(long value, int size) { return String.format("%" + size + "s", Long.toBinaryString(Math.abs(value))).replace(" ", "0"); } }