Follow along with the video below to see how to install our site as a web app on your home screen.
Anmerkung: This feature currently requires accessing the site using the built-in Safari browser.
@hagbard23
Schau mal hier
Benchmark c++ vs java
Auch wenn eclipse ein Speicherfresser sein sollte, liegt das nicht an Java, sondern daran wie eclipse programmiert ist.
Wie gesagt, dass Java langsam war, ist schon ein paar Jahre her. [...]
Uhm zerix, der Fazit deines links: "C++ is well over twice as fast as Java -s". Du hast also gerade nen Beleg geliefert dass Java nicht die schnellste Plattform ist.
public class VectorInteger {
public static void main(String[] args) {
long time = System.currentTimeMillis();
int x = 2147483647;
Liste l = new Liste();
Liste alt = l;
for(int i = 0; i < 10000000;i++){
l.i = x;
l.next = new Liste();
l = l.next;
}
long time2 = System.currentTimeMillis();
System.out.println(time2-time);
}
}
class Liste{
int i;
Liste next;
}
4672
#include <iostream>
#include "windows.h"
int main()
{
struct MListe{
int i;
MListe *next;
};
SYSTEMTIME now;
GetSystemTime(&now);
long time = now.wSecond*1000 + now.wMilliseconds;
int i=0;
MListe *list = new MListe;
MListe *save = list;
for(i;i<10000000;i++){
list->i = 2147483647;
list->next = new MListe;
list = list->next;
}
GetSystemTime(&now);
long time2 = now.wSecond*1000 + now.wMilliseconds;
std::cout<<time2 - time;
return 0;
}
4797