mirror of
https://github.com/TheAlgorithms/Java.git
synced 2025-07-27 06:23:08 +08:00
style: enable MultipleVariableDeclarations
in checkstyle (#5175)
Co-authored-by: vaibhav <vaibhav.waghmare@techprescient.com>
This commit is contained in:
@ -13,7 +13,8 @@ public final class NonRepeatingElement {
|
||||
|
||||
public static void main(String[] args) {
|
||||
try (Scanner sc = new Scanner(System.in)) {
|
||||
int i, res = 0;
|
||||
int i;
|
||||
int res = 0;
|
||||
System.out.println("Enter the number of elements in the array");
|
||||
int n = sc.nextInt();
|
||||
if ((n & 1) == 1) {
|
||||
@ -42,7 +43,8 @@ public final class NonRepeatingElement {
|
||||
|
||||
// Finding the rightmost set bit
|
||||
res = res & (-res);
|
||||
int num1 = 0, num2 = 0;
|
||||
int num1 = 0;
|
||||
int num2 = 0;
|
||||
|
||||
for (i = 0; i < n; i++) {
|
||||
if ((res & arr[i]) > 0) { // Case 1 explained below
|
||||
|
Reference in New Issue
Block a user