RandSync - A randomized linear algorithm for clock synchronization in multi-agent systems