Recent content by ZKR

  1. Z

    RCA cable quality effects on sound and noise

    Ok, I have a new PC now, Asus p8Z77-V LX motherboard with an on-board realtek sound card. Replaced the old crappy cables too, but with the same lowest quality cables (just longer). Electronic noise has been reduced dramatically, unnoticeable till 80% volume. If I disconnect the plug from the...
  2. Z

    RCA cable quality effects on sound and noise

    Hey guys I have a Rotel RA-971 Amplifier with B&W speakers (both 12 years old). Connected to a motherboard (Asus Z77) Realtek onboard audio. I have a "siffing" noise, like electricity noise, hearable when no sound and on high volume. Would mid quality RCA cables affects the sound quality and...
  3. Z

    Recursive boolean

    Best answer selected by ZKR.
  4. Z

    Recursive boolean

    Well, meanwhile I have completed my own version. It might be a mammoth, but it was obtained by sweat and blood. Some of the fixes were done thanks to your help, thanks. my code: public static boolean checkGCD (int[] values) { int num1 = 0, num2 = num1+1; return (GCD.checkGCD(num1...
  5. Z

    Recursive boolean

    When tested for : 1, 3, 5, 7, 11, (I have inserted a println in gcd) result: CGD of 3 and 3 is : 3 Numbers in the array are not coprime. It only checked those values, and checked one with itself.
  6. Z

    Recursive boolean

    The task are: gcd method: To find the gdc of 2 integers (accepting (int num1, int num2) checkGCD method: to assure that all numbers in the array are gdc=1 with each other. It checks all numbers in the array with all others. So that : {4, 7, 8, 9} is checked: 4, 7 | 4,8 | 4,9 7,8 | 7,9 | 8,9...
  7. Z

    Recursive boolean

    Wow Const, it`s ingenious, I am quite ashame of my cumbersome gcd public static int gcd (int n, int m) { int larger, smaller, commonGD; if (n > m) // Determines greater integer then assigns values for further processing { larger = n; smaller = m; } else { larger = m...
  8. Z

    Recursive boolean

    The heading of `checkGCD` should be: public static boolean checkGCD (int[] values) If it calls itself with method overloading passing the data you added ((int g, int j, int n, int[] array)) is it still considered recursive? What should 'n' be assigned to? When I assign it to values.length it...
  9. Z

    Recursive boolean

    Hello, help needed again. I have successfully written a method that accepts 2 integers and checks for a great common divider using a Euclidean algorithm. Now I have to write a recursive method which accepts an array, and returns True if all numbers in the array are Coprime (dividable by '1'...
  10. Z

    Searching the most efficient way

    Best answer selected by ZKR.
  11. Z

    Searching the most efficient way

    Thanks, good advice on the termination. I didn`t do that because I read in the book (a good one actually) that it`s not a good practice to have 2 return statements in the same method. Now the assignment was corrected by them in the course forum and they underline that the A Array is sorted (we...
  12. Z

    Searching the most efficient way

    " Return true as soon as you find a match. Don't continue to loop through the arrays, as this just adds an unnecessary overhead. The last statement in the method can be "return false", because you'll only hit this if you have gone through the whole of array a. " Yes I changed it: public...
  13. Z

    Searching the most efficient way

    Hey all. I have to write a method that accepts 2 arrays and checks if any number in Array_B contains the sum of any subsequent members in Array_A. 1. Does subsequent means that if the array is {1, 3, 4, 5} I should compare: 1+3, 3+4, 4+5 OR : 1+3, 4+5 (in pairs) 2. It is said, assume...
  14. Z

    Scanner class help

    Thanks. That`s what I did, 2 scanners.
  15. Z

    Scanner class help

    Best answer selected by ZKR.