| 1 | class Solution { |
| 2 | public int minBitFlips(int start, int goal) { |
| 3 | int xor = start ^ goal; |
| 4 | int count=0; |
| 5 | while(xor>0){ //set bits O(32) |
| 6 | xor = xor & (xor-1); |
| 7 | count++; |
| 8 | } |
| 9 | return count; |
| 10 | } |
| 11 | } |
nothing calls this directly
no outgoing calls
no test coverage detected