Changes

From Genome Analysis Wiki
Jump to navigationJump to search
no edit summary
Line 79: Line 79:  
   myTree<int> c3;
 
   myTree<int> c3;
 
   std::set<int> s;
 
   std::set<int> s;
 
+
 
   clock_t start = clock();
 
   clock_t start = clock();
 
   for(int i=0; i < (int)v.size(); ++i) {
 
   for(int i=0; i < (int)v.size(); ++i) {
Line 87: Line 87:  
   double duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   double duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   std::cout << "Sorted Array (Insert) " << duration << std::endl;
 
   std::cout << "Sorted Array (Insert) " << duration << std::endl;
 
+
 
   start = clock();
 
   start = clock();
 
   for(int i=0; i < (int)v.size(); ++i) {
 
   for(int i=0; i < (int)v.size(); ++i) {
Line 95: Line 95:  
   duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   std::cout << "List (Insert) " << duration << std::endl;
 
   std::cout << "List (Insert) " << duration << std::endl;
 
+
 
 
   start = clock();
 
   start = clock();
 
   for(int i=0; i < (int)v.size(); ++i) {
 
   for(int i=0; i < (int)v.size(); ++i) {
Line 103: Line 103:  
   duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   std::cout << "Tree (Insert) " << duration << std::endl;
 
   std::cout << "Tree (Insert) " << duration << std::endl;
 
+
 
   start = clock();
 
   start = clock();
 
   for(int i=0; i < (int)v.size(); ++i) {
 
   for(int i=0; i < (int)v.size(); ++i) {
Line 111: Line 111:  
   duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   std::cout << "std::set (Insert) " << duration << std::endl;
 
   std::cout << "std::set (Insert) " << duration << std::endl;
 
+
 
   start = clock();
 
   start = clock();
 
   for(int i=0; i < (int)v.size(); ++i) {
 
   for(int i=0; i < (int)v.size(); ++i) {
Line 119: Line 119:  
   duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   std::cout << "Sorted Array (Search) " << duration << std::endl;
 
   std::cout << "Sorted Array (Search) " << duration << std::endl;
 
+
 
   start = clock();
 
   start = clock();
 
   for(int i=0; i < (int)v.size(); ++i) {
 
   for(int i=0; i < (int)v.size(); ++i) {
Line 127: Line 127:  
   duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   std::cout << "List (Search) " << duration << std::endl;
 
   std::cout << "List (Search) " << duration << std::endl;
 
+
 
   start = clock();
 
   start = clock();
 
   for(int i=0; i < (int)v.size(); ++i) {
 
   for(int i=0; i < (int)v.size(); ++i) {
Line 135: Line 135:  
   duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   duration = (double)(finish-start)/CLOCKS_PER_SEC;   
 
   std::cout << "Tree (Search) " << duration << std::endl;
 
   std::cout << "Tree (Search) " << duration << std::endl;
 
+
 
   start = clock();
 
   start = clock();
 
   for(int i=0; i < (int)v.size(); ++i) {
 
   for(int i=0; i < (int)v.size(); ++i) {

Navigation menu