
























private String returnFullTimes(int theSecond) { int h = 0, m = 0, s = 0; h = (int)Math.Floor(theSecond / 3600.0); if (h > 0) { m = (int)Math.Floor((theSecond - h * 3600.0) / 60); if (m > 0) { s = theSecond - h * 3600 - m * 60; } else { s = theSecond - h * 3600; //原来这里写错了,写成了s = theSecond; } } else { m = (int)Math.Floor(theSecond / 60.0); if (m > 0) { s = theSecond - m * 60; } else { s = theSecond; } } return h + "时" + m + "分" + s + "秒"; }
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。