riku
2021-11-10 665a2e1098fb52800ac7624d4a32dfeb6ce15151
1
2
3
4
5
6
7
8
9
10
11
12
13
package com.flightfeather.uav.dataprocess
 
import kotlin.math.round
 
data class AvgPair(
    var t: Float, var c: Int
){
    fun avg(): Float = if (c == 0) {
        0f
    } else {
        round(t / c * 1000) / 1000
    }
}