All pastes #715110 Raw Edit

Miscellany

public cpp v1 · immutable
#715110 ·published 2007-09-26 01:14 UTC
rendered paste body
#include <iostream>#include <string>#include <stdlib.h>#include <stdio.h>#include <windows.h>using namespace std;class CPrecisionTimer{LARGE_INTEGER lFreq, lStart;public:CPrecisionTimer(){QueryPerformanceFrequency(&lFreq);}inline void Start(){QueryPerformanceCounter(&lStart);}inline double Stop(){LARGE_INTEGER lEnd;QueryPerformanceCounter(&lEnd);return (double(lEnd.QuadPart - lStart.QuadPart) / lFreq.QuadPart);}};int main(int argc, char *argv[]){CPrecisionTimer cptimer;//Loop for second number                for(int j=130; j<1000; ++j)                {                        for(int k=100; k<200; ++k)        {                        for(int i=308; i<400; ++i){                        //Set the app run info                        string run="app13win 537 ";                        char temp[11];                        itoa(i, temp, 10);                        run += temp;                        run += " ";                        itoa(k, temp, 10);                        run += temp;                        run += " ";                        itoa(j, temp, 10);                        run += temp;                        //cptimer.Start();                        system(run.c_str());                        cout << run << "\n";// for debugging                       // currentTime=cptimer.Stop();                       /// if(maxTime<currentTime)                       // {                       // maxTime=currentTime;                       // maxTimeI=i;                      //  }                        //cout<<"\n\n Max time: "<<maxTime<<" on number: "<<maxTimeI<<endl;                        //}                       // break;                         //}                  }        }}return 0;}