Ejemplo n.º 1
0
int main(void) {
  double timeAverage_Trad = 0;
  double timeAverage_Vect = 0;

  bodyData body1, body2;
  // B1, Pos = (1,1)
  body1.bodyMass = 1;
  body1.bodyPosition[0] = 1;
  body1.bodyPosition[1] = 2;
  // B2, Pos = (1,1)
  body2.bodyMass = 1;
  body2.bodyPosition[0] = 4;
  body2.bodyPosition[1] = 6;
  
  for(int id = 0; id < ATIMES; id++) {
    timeAverage_Trad += trad(body1, body2);
    timeAverage_Vect += vect(body1, body2);
    
    ++body1.bodyMass;
    ++body1.bodyPosition[0];
    ++body1.bodyPosition[1];
  }
  
  timeAverage_Trad /= ATIMES;
  timeAverage_Vect /= ATIMES;
  
  printf("TT: %G\n", timeAverage_Trad);
  printf("TV: %G\n", timeAverage_Vect);
  
  return 0;
}
Ejemplo n.º 2
0
QString TranslatorTab::getTranslator() const
{
    return QString(
               tr("The following people have contributed with translations:")
               + "<ul>"
               + trad(tr("Simplified-Chinese"), "Yichi Zhang &lt;[email protected]&gt;")
               + "</ul>"
           );
}