| kemi (statz) | ![]() #2, Főfasz (2982) |
2393 | #2447 | ^ | Idézet | Fri, 15 Mar 2013 15:04:52 +01 |
| 178.164.*.* |
|
*.pool.digikabel.hu |
C/C++#include <stdio.h>
//ugyanez a kód lefordul C meg C++ compilerrel is
int main() {
int i, j;
for (i = 0; i < 1000; i++) {
for (j = 0; j < 100; j++) {
printf("%d\n", j);
}
}
return 0;
}Java package javatest;
public class Main {
public static void main(String[] args) {
for (int i = 0; i < 1000; i++) {
for (int j = 0; j < 100; j++) {
System.out.println(j);
}
}
}
}C# class cs {
static void Main() {
for (int i = 0; i < 1000; i++) {
for (int j = 0; j < 100; j++) {
System.Console.WriteLine(j);
}
}
}
}PS C:\Users\kemi242\Desktop\csc> measure-command {.\c.exe}
Days : 0
Hours : 0
Minutes : 0
Seconds : 0
Milliseconds : 978
Ticks : 9783411
TotalDays : 1,13233923611111E-05
TotalHours : 0,000271761416666667
TotalMinutes : 0,016305685
TotalSeconds : 0,9783411
TotalMilliseconds : 978,3411
PS C:\Users\kemi242\Desktop\csc> measure-command {.\cpp.exe}
Days : 0
Hours : 0
Minutes : 0
Seconds : 1
Milliseconds : 155
Ticks : 11555819
TotalDays : 1,33747905092593E-05
TotalHours : 0,000320994972222222
TotalMinutes : 0,0192596983333333
TotalSeconds : 1,1555819
TotalMilliseconds : 1155,5819
PS C:\Users\kemi242\Desktop\csc> measure-command {.\cs.exe}
Days : 0
Hours : 0
Minutes : 0
Seconds : 1
Milliseconds : 753
Ticks : 17532178
TotalDays : 2,02918726851852E-05
TotalHours : 0,000487004944444444
TotalMinutes : 0,0292202966666667
TotalSeconds : 1,7532178
TotalMilliseconds : 1753,2178
PS C:\Users\kemi242\Desktop\csc> measure-command {java -jar java.jar}
Days : 0
Hours : 0
Minutes : 0
Seconds : 3
Milliseconds : 867
Ticks : 38679832
TotalDays : 4,47683240740741E-05
TotalHours : 0,00107443977777778
TotalMinutes : 0,0644663866666667
TotalSeconds : 3,8679832
TotalMilliseconds : 3867,9832A measure-command parancs eldobja a kimenetet, az nem tudom változtat-e az eredményen valamit. |