Showing 147 of 294 total issues
Method sort
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
@Override
public short[] sort(short[] arr, int start, int end) {
if (end > start) {
if (end - start < 10) {
return insertionSort.sort(arr, start, end);
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method sort
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
@Override
public int[] sort(int[] arr, int start, int end) {
if (end > start) {
if (end - start < 10) {
return insertionSort.sort(arr, start, end);
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method select
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
T[] S, int[] freq, int[] index, int start, int end, int k, Comparator<T> comparator) {
Method select
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public <T> int select(T[] S, int[] freq, int start, int end, int k, Comparator<T> comparator) {
Method partitionByMedian
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
protected int partitionByMedian(double[] S, int[] freq, int[] indices, int low, int high) {
final int arraysize = high - low;
double[] subList = new double[(arraysize + 4) / 5];
int[] subListFreq = null;
if (freq != null) {
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method cycle
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public double[] cycle(double[] S, int first, int second, int third, int fourth, int fifth) {
Method cycle
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public double[] cycle(double[] S, int first, int second, int third, int fourth, int fifth) {
Method cycle
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
double[] cycle(double[] S, int first, int second, int third, int fourth, int fifth);
Method cycle
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public float[] cycle(float[] S, int first, int second, int third, int fourth, int fifth) {
Method cycle
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
<T> T[] cycle(T[] S, int first, int second, int third, int fourth, int fifth);
Method select
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
protected int select(short[] S, int[] freq, int[] index, int start, int end, int k) {
Method select
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
protected int select(int[] S, int[] freq, int[] index, int start, int end, int k) {
Method cycle
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public <T> T[] cycle(T[] S, int first, int second, int third, int fourth, int fifth) {
Method cycle
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
float[] cycle(float[] S, int first, int second, int third, int fourth, int fifth);
Method cycle
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public float[] cycle(float[] S, int first, int second, int third, int fourth, int fifth) {
Method cycle
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public int[] cycle(int[] S, int first, int second, int third, int fourth, int fifth) {
Method cycle
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public <T> T[] cycle(T[] S, int first, int second, int third, int fourth, int fifth) {
Method partitionByMedian
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
protected int partitionByMedian(int[] S, int[] freq, int[] indices, int low, int high) {
final int arraysize = high - low;
int[] subList = new int[(arraysize + 4) / 5];
int[] subListFreq = null;
if (freq != null) {
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method cycle
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public float[] cycle(float[] S, int first, int second, int third, int fourth, int fifth) {
Method select
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
protected int select(char[] S, int[] freq, int[] index, int start, int end, int k) {