formatting and fixes

This commit is contained in:
2024-06-03 08:20:20 -05:00
parent 0e4c24a23d
commit 94d86a1c9f
37 changed files with 2742 additions and 2559 deletions

View File

@@ -1,5 +1,5 @@
#include <dtl/dtl.hpp>
#include "common.hpp"
#include <dtl/dtl.hpp>
#include <iostream>
#include <string>
@@ -9,30 +9,30 @@ using namespace std;
using dtl::Diff;
int main(int argc, char *argv[]){
if (isFewArgs(argc)) {
cerr << "Too few arguments." << endl;
return -1;
}
typedef char elem;
typedef string sequence;
int main(int argc, char *argv[]) {
sequence A(argv[1]);
sequence B(argv[2]);
Diff< elem, sequence > d(A, B);
d.compose();
// Shortest Edit Script
cout << "SES" << endl;
if (isFewArgs(argc)) {
cerr << "Too few arguments." << endl;
return -1;
}
string result;
typedef char elem;
typedef string sequence;
d.storeSES < string, CustomStorage > (result);
sequence A(argv[1]);
sequence B(argv[2]);
cout << result;
return 0;
Diff<elem, sequence> d(A, B);
d.compose();
// Shortest Edit Script
cout << "SES" << endl;
string result;
d.storeSES<string, CustomStorage>(result);
cout << result;
return 0;
}