some golang functions