⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 time.cpp

📁 一个将binary转化为cpp的转换程序
💻 CPP
字号:
/*************************************************************************** *  Filename :  Time.cpp *  Started  :  10/??/04 *  Copyright:  (C) 2004 Christian Petri *  Email    :  viperb0y@users.sourceforge.net * * *  This program is free software; you can redistribute it and/or modify *  it under the terms of the GNU General Public License as published by *  the Free Software Foundation; either version 2 of the License, or *  (at your option) any later version. * ***************************************************************************/#include <sys/time.h>#include <cstdlib>#include "Time.h"Time::Time(){}Time::~Time(){}void Time::start(){  gettimeofday(&now, NULL);  clock_s = (now.tv_sec) * 1000 + (now.tv_usec )/ 1000;}void Time::stop(){  gettimeofday(&now, NULL);  clock_e = (now.tv_sec) * 1000 + (now.tv_usec )/ 1000;}float Time::result(){  return static_cast<float>((clock_e - clock_s) / 1000);}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -