-
Notifications
You must be signed in to change notification settings - Fork 16
/
Copy pathMath.kt
45 lines (37 loc) · 810 Bytes
/
Math.kt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
package com.madrapps.jacoco
class Arithmetic {
fun add(a: Int, b: Int): Int {
if (a < b) {
// Do nothing
}
return a + b
}
fun subtract(a: Int, b: Int): Int {
if (a > b) {
return a - b
} else {
return a - b
}
}
fun multiply(a: Int, b: Int): Int {
// Some comment here
return a * b
}
fun divide(a: Int, b: Int): Int {
if (a > b) {
return a / b
} else {
return a / b
}
}
fun modulo(a: Int, b: Int): Int {
// Some comment for non-covered method
return a % b
}
fun area(a: Int, b: Int): Int {
return a * b
}
fun volume(a: Int, b: Int, c: Int): Int {
return a * b * c
}
}