Clover icon

jalviewX

  1. Project Clover database Wed Oct 31 2018 15:13:58 GMT
  2. Package jalview.util

File MathUtils.java

 

Coverage histogram

../../img/srcFileCovDistChart10.png
0% of files have more coverage

Code metrics

2
3
1
1
22
12
2
0.67
3
1
2

Classes

Class Line # Actions
MathUtils 3 3 2 0
1.0100%
 

Contributing tests

This file is covered by 3 tests. .

Source view

1    package jalview.util;
2   
 
3    public class MathUtils
4    {
5   
6    /**
7    * Returns the greatest common divisor of two integers
8    *
9    * @param a
10    * @param b
11    * @return
12    */
 
13  50 toggle public static int gcd(int a, int b)
14    {
15  50 if (b == 0)
16    {
17  21 return Math.abs(a);
18    }
19  29 return gcd(b, a % b);
20    }
21   
22    }