Java Bits Convert to bit(int a, int b)

Here you can find the source of bit(int a, int b)

Description

bit

License

Open Source License

Declaration

static int bit(int a, int b) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    static int bit(int a, int b) {
        return (a & (1 << b)) >> b;
    }//from  w w  w .  ja  v a  2 s. c  om
}

Related

  1. bit(byte[] h, int i)
  2. bit(int row, int col)
  3. BIT(int x)
  4. bitArray2byte(boolean[] array)
  5. bitarrayShiftAndFill(byte[] data, int length, int shift, byte first, byte last)