Skip to content

Instantly share code, notes, and snippets.

@ericsson49
ericsson49 / clock_sync.kt
Created Feb 24, 2020
Simulation of simple clock fusion protocol
View clock_sync.kt
import kotlin.math.floor
import kotlin.math.max
import kotlin.math.min
import kotlin.math.round
import kotlin.random.Random
const val N = 10000
const val rho = 0.0
const val minD = 0
const val maxD = 1000